Answer the question
In order to leave comments, you need to log in
Why does Gulp-watch's error listener fire on ruby-haml only the first time?
There is the following code in gulpfile.js:
//Function for error log
function log(error) {
console.log([
'',
"===== ERROR MESSAGE START =====".bold.red,
('[' + error.name + ' in ' + error.plugin + ']').bold.green,
error.message,
"===== ERROR MESSAGE END =======".bold.red,
''
].join('\n'));
this.end();
}
...
gulp.task('watch', function() {
// .. Layouts
gulp.src([path.layouts.all, path.layouts.views.none])
.pipe(plugin.watch([path.layouts.all, path.layouts.views.none]))
.pipe(plugin.rubyHaml()).on('error', log) //error log here
.pipe(gulp.dest(path.build));
});
...
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question