K
K
Kizzeon2020-02-13 19:09:21
css
Kizzeon, 2020-02-13 19:09:21

Node SASS vs Dart SASS. Which is more productive under what conditions?

It became interesting which SASS ->CSS compiler is more productive and which one is more suitable for me in the project.
At the moment I'm using the default gulp-sass

Task code in gulpfile:

gulp.task('styles', function() {
    return gulp.src('app/sass/main.sass')
        .pipe(sass().on('error', sass.logError))
        .pipe(concat('style.css'))
        .pipe(gulp.dest('app/css'))
        .pipe(browserSync.reload({ stream: true }))
});


The plugin page talks about node sass and dart sass.
And also, by interest, I entered a search by popularity for the query "sass" and got more popular options.
For example
  1. sass-loader
  2. sass


In general my questions are:

  1. What's the difference between Node Sass and Dart sass?
  2. What is more productive? Yes, I know that there are microseconds, but it's still nicer to use a faster option.
  3. Why are other plugins (listed above) more popular than grunt and gulp sass?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
F
Flying, 2020-02-13
@Kizzeon

  1. dart-sass - reference implementation of the language i.e. is an example of how the language should work. node-sass binding libsass ( C++ language specification implementations ) to node.js.
    dart-sass contains all the latest features of the language, for example, there is already support for sass modules , libsass lags behind, and node-sass lags behind libsass. For proof - here and here
  2. libsass is more productive, in some places - significantly. For example, in my tests, intensive work with sass maps in libsass is about 10 times faster than in dart sass. As for microseconds - I have projects that take 15-20 seconds to compile only styles on node-sass, everything is much slower on dart-sass
  3. The references given are a comparison of warm with soft. There are implementations of languages, and there are plugins for connecting them to various collectors. sass - language implementation itself, gulp-sass - binding for Gulp, sass-loader - binding for Webpack

A
Andrey Titov, 2020-12-06
@titov_andrei

Why rewrite Sass?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question