0
這種重複是不對的。你應該怎麼用Gulp做這個?重複在吞嚥
gulp.task("default", function() {
gulp.src("src/**/*.cjsx")
.pipe(cjsx({bare: true}).on("error", gutil.log))
.pipe(sourcemaps.init())
.pipe(transpile({
formatter: "bundle"
}))
.pipe(sourcemaps.write("./"))
.pipe(gulp.dest("public"));
gulp.src("src/**/*.js")
.pipe(sourcemaps.init())
.pipe(transpile({
formatter: "bundle"
}))
.pipe(sourcemaps.write("./"))
.pipe(gulp.dest("public"));
});