Answer the question
In order to leave comments, you need to log in
How to speed up sass compilation?
When there are more than ten .sass files, compilation starts to take more than one minute.
Compiling with gulp-sass
. the first thing that came to mind was to connect gulp-newer
, but the following problems appear with it ... The .sass
entry point is main.sass
, which imports all other files into itself. And when I compile only the changed files, then changes occur in a separate file, but main.css
not in the merged one.
Is there a way out of this situation?
Answer the question
In order to leave comments, you need to log in
It looks like you misorganized the file structure. By the way, in my projects, on average, there are 30-40 files (components and blocks, all in separate files) and compilation takes no more than 2 seconds.
The entry point is the main.sass file, it only contains file imports.
Check the organization of gulp tasks.
PS: assembly for working with Gulp, Sass, Foundation. Compare gullfiles, I hope it will help speed up the process.
Use libsass, not ruby gem.
But in general, even when using the ruby version, a minute is an incredibly long time. In our Ruby project with a customized Foundation, compass and hundreds of files connected, it took 20 seconds in the worst case.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question