I'm trying to switch from gulp-ruby-sass
to node-sass
which is based on libsass
a C implementation faster than the classic Ruby version.
So far I've install the node packages:
Node package
cd /path/to/project
npm install --save-dev node-sass gulp-sass
Gulpfile
I replaced the requirement as follow:
//sass = require('gulp-ruby-sass'),
sass = require('gulp-sass'),
Libsass
Then I went to lo for a libsass
package, but none is available currently.
So I wonder if anyone as a bash script to build it as current instructions are unclear ?
Best Answer
I documented my research as a bash script as a gist based on the official doc
Compiling and Installing
libsass
andsassc
Install dependencies
Fetch sources
Create configure script
Create custom makefiles for shared library
For more info read: Difference between static and shared libraries? before installing
libsass
.Build the library
Install the library
Testing
Only
node-sass
Succeed with
Gulp
withruby-sass
Gulp
withnode-sass
Conclusion
My tests are no benchmark and have little value but
node-sass
seems to be 3-5x faster thanruby-sass
.