Coder Social home page Coder Social logo

Comments (4)

es128 avatar es128 commented on June 8, 2024
  1. The redundant dependency compiles in brunch have been fixed. At this point, the slowness is entirely on the sass gem.
  2. https://github.com/andrew/node-sass should theoretically be much faster, but it doesn't currently support compass. Until it does, I'm not motivated to integrate it into a plugin. I'm now watching sass/libsass#82, so if/when compass support does come this may be worthwhile. It also supports only the SCSS syntax, but theoretically https://github.com/emirotin/node-sass-indented can take care of that.
  3. If the compile time bothers you and you're not using compass or other very sass-specific features (or even if you are), then just switch to stylus. Seriously. The basic syntax is already compatible, so in many cases you might not need to do anything more than switch the file extension.

from sass-brunch.

michaek avatar michaek commented on June 8, 2024

I appreciate all the work that's been done for this - it's indeed much faster!

However, in my testing, Sass's watch is still much faster (though specifically when using Compass), presumably because Sass and its dependencies remain in memory in the Ruby process. I've used sass --watch --compass app/styles:app/assets/stylesheets - the assets path is to get Brunch to pick up the changes for auto-reload - and that works well, but I'd love to have only one command to run to get everything going.

I'm curious if you looked into spawning a sass --watch child process and piping the output through Brunch's CLI process. If not, I would be interested in trying to support that. If you'd looked into it and it seemed impractical, though, I won't go down the same rabbit hole. :)

from sass-brunch.

es128 avatar es128 commented on June 8, 2024

No I never tried it. Feel free to give it a shot. Can sass --watch output to stdout?

Also with the workflow you described it would appear you're missing out on the concatenation of the style files?

The next thing I intend to do for this is brunch/brunch#651, although that won't be helpful if you're actively editing the sass.

from sass-brunch.

michaek avatar michaek commented on June 8, 2024

I'm concatenating the vendor files, but importing all the app Sass into a single file. I agree that assets isn't the best place for it if I want to take advantage of concatenation and minification.

Here's the solution I've hit upon: I'm using Foreman with the Procfile:

brunch: brunch watch --server
sass: bundle exec compass watch

That way, I get the watch scripts running (and combined output) with just

$ foreman start

from sass-brunch.

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.