javascript - When using gulp image to compress and copy files, the error events.js:160 is reported? Is my nodejs version wrong?
PHPz
PHPz 2017-05-16 13:36:10
0
2
660

The executed js code is as follows

gulp.task('image',function () {
    gulp.src(app.srcPath + 'image/**/*')
        .pipe(gulp.dest(app.devPath + 'image'))
        .pipe($.imagemin())
        .pipe(gulp.dest(app.prdPath + 'image'));
});

The error report that appears is as shown

It said that enoent.js under cross-spawn was not found? ? ? I would like to ask, what plug-in does cnpm need to install for this?

PHPz
PHPz

学习是最好的投资!

reply all(2)
巴扎黑
rm -rf node_modules/ && npm cache clean && npm i

It reminds you that your image task has ended. Should it be a problem with the next task?

某草草

Is the path of your gulp.src correct? Is it app.srcPath+'/image' written like this

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template