GithubHelp home page GithubHelp logo

Comments (9)

hlascelles avatar hlascelles commented on August 17, 2024

Ah, just seen the settings section, trying it now...

from less-sbt.

hlascelles avatar hlascelles commented on August 17, 2024

Filters worked, but includes don't... Am getting:

Lift/compile:less: error occured while compiling /less/bootstrap.less: TypeError: Cannot call method "slice" of undefined (less-rhino-1.1.3.js#2404)

Using: sbt 0.11.0

Thanks for any guidance!

from less-sbt.

softprops avatar softprops commented on August 17, 2024

Hey thanks for reporting to this. I try to get to it tonight.

from less-sbt.

softprops avatar softprops commented on August 17, 2024

@hlascelles would you mind cloning this locally and doing a publish local to see if these changes fix your build. The version should now be @ 0.1.2-SNAPSHOT so update your projects plugin def after publishing locally.

I wrote a scripted test should should test that imports work. The test is basically that I have a a.less file which imports a variale from b.less and assert it gets properly injected. I also don't think it hurts to have b.less included but if you wanted to exclude it. use

(LessKeys.excludeFilter in (Compile, LessKeys.less)) ~= { ff => ff || "b.less" }

If you were curious ~= augments an existing setting. So here I am saying take the original filter and add an or condition of the file I want to exclude.

See https://github.com/softprops/less-sbt/blob/master/src/sbt-test/less-sbt/imports/build.sbt#L3 for what I mean.

If this fixes your build, I'll do a 0.1.2 release

from less-sbt.

dimensia avatar dimensia commented on August 17, 2024

I am seeing this issue as well. For now I just copied all the data from my include file into the main file and it seems to work.

from less-sbt.

softprops avatar softprops commented on August 17, 2024

Did either of you try my fix yet? I have a scripted test for this use case which I thinks fixes the issue but I'd like to get one of you guys to do a publish local to see if it fixes your specific issue before I do another release

You can see the test project at

https://github.com/softprops/less-sbt/tree/master/src/sbt-test/less-sbt/imports

My test case was simple, I had a.less import a property from b.less and then validated that what was generated was what I expected

https://github.com/softprops/less-sbt/blob/master/src/sbt-test/less-sbt/imports/src/main/less/a.less

Confirmation on whether this fix helps your issues would help my confidence in pushing the fix in a new release.

from less-sbt.

dimensia avatar dimensia commented on August 17, 2024

I just tried 0.1.2-SNAPSHOT and it worked for me.

from less-sbt.

softprops avatar softprops commented on August 17, 2024

Okay thanks @dimensia. Thanks for testing. I'll push an 0.1.2 release tomorrow

from less-sbt.

softprops avatar softprops commented on August 17, 2024

published http://implicit.ly/less-sbt-012

from less-sbt.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.