-
Notifications
You must be signed in to change notification settings - Fork 4
Open
Description
Any help greatly appreciated
Currently have my onError set up as so:
const onError = function(err) {
notify.onError({
title: "Gulp",
subtitle: "πΊ Fail",
message: "Error: <%= error.message.toString() %>",
sound: "Frog"
})(err);
this.emit('end');
};
and scripts task:
function scripts() {
return (
gulp
.src(JS.src, { sourcemaps: true})
.pipe(terser2({
ecma: 6,
keep_fnames: false,
mangle: {
toplevel: false,
},
}))
.on('error', function (error) {
if (error.plugin !== "gulp-terser-js") {
console.log(error.message)
}
this.emit('end')
})
.pipe(plumber({errorHandler: onError}))
.pipe(gulp.dest(JS.build, { sourcemaps: true }))
.pipe(browsersync.stream())
.pipe(notify({
title: 'Gulp',
subtitle: 'β
Success',
message: 'Js compiled',
sound: "Pop"
}))
);
}
package.json:
"gulp": "^4.0.2",
"gulp-notify": "^3.2.0",
"gulp-terser-js": "^5.2.2",
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels