Answer the question
In order to leave comments, you need to log in
What is the benefit of adding the sync() function to gulp-sass?
How is the standard code different:
'use strict';
var gulp = require('gulp');
var sass = require('gulp-sass');
gulp.task('sass', function () {
gulp.src('./sass/**/*.scss')
.pipe(sass().on('error', sass.logError))
.pipe(gulp.dest('./css'));
});
gulp.task('sass:watch', function () {
gulp.watch('./sass/**/*.scss', ['sass']);
});
'use strict';
var gulp = require('gulp');
var sass = require('gulp-sass');
gulp.task('sass', function () {
gulp.src('./sass/**/*.scss')
.pipe(sass.sync().on('error', sass.logError))
.pipe(gulp.dest('./css'));
});
gulp.task('sass:watch', function () {
gulp.watch('./sass/**/*.scss', ['sass']);
});
Answer the question
In order to leave comments, you need to log in
You can also compile synchronouslyhttps://github.com/dlmanning/gulp-sass#basic-usage
and in the second they will be compiled in parallel / synchronously or what?On the contrary, synchronously = sequentially.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question