gulp.run is deprecated. How do I compose tasks?

后端 未结 10 1236
感情败类
感情败类 2020-12-22 18:57

Here is a composed task I don\'t know how to replace it with task dependencies.

...
gulp.task(\'watch\', function () {
 var server = function(){
  gulp.run(\         


        
10条回答
  •  时光取名叫无心
    2020-12-22 19:44

    In Gulp 4 the only thing that seems to be working for me is:

    gulp.task('watch', function() {
        gulp.watch(['my-files/**/*'], gulp.series('my-func'));
    });
    
    gulp.task('my-func', function() {
        return gulp.src('[...]').pipe(gulp.dest('...'));
    });
    

提交回复
热议问题