Logging Gulp Errors

less than 1 minute read

While building Aurelia applications, I have occassionaly made changes that cause the gulp build process to crash. It is very easy to add console logging to your gulp steps so you can see exactly what the problem is.

gulp.task('build-html', function() { 
  return gulp.src(paths.html) 
    .pipe(changed(paths.output, {extension: '.html'})) 
    .pipe(htmlmin({collapseWhitespace: true})) 
    .pipe(htmlmin({collapseWhitespace: true}).on('error', function(e){ 

Leave a Comment