gulp-usemin
gulp-usemin copied to clipboard
TypeError: listener must be a function
Hi !
I've just updated modules with npm update
and have currently this issue after the upgrade :
[12:55:30] 'build-usemin' errored after 51 ms
[12:55:30] TypeError: listener must be a function
at TypeError (native)
at Stream.addListener (events.js:142:11)
gulp : 3.9.0
gulp-usemin : 0.3.14
Task :
gulp.task('build-html', function() {
return gulp.src(paths.html)
.pipe(plumber())
.pipe($.if($.isBuild, $.usemin({
js: [$.uglify({
mangle: true,
compress: true
}), $.rev()]
})))
.pipe(
$.if(!$.isBuild,
$.usemin()
)
)
.pipe(gulp.dest(paths.output));
});
Hoping this could help !