Skip to content

Commit 385748d

Browse files
committed
feat(gulp): 第一次启动时也编译
1 parent 3189f29 commit 385748d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

gulpfile.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,13 @@ const watch = require('gulp-watch');
55
gulp.task('default', ['compileJS', 'moveConfig']);
66

77
gulp.task('compileJS', [], function() {
8-
return watch('src/**/*.js', { verbose: true })
8+
return watch('src/**/*.js', { verbose: true, ignoreInitial: false })
99
.pipe(babel({presets: ['es2015']}))
1010
.pipe(gulp.dest('lib'));
1111
})
1212

1313
gulp.task('moveConfig', [], function() {
14-
return watch('src/config/**/*.*', { verbose: true }, () => {
14+
return watch('src/config/**/*.*', { verbose: true, ignoreInitial: false }, () => {
1515
gulp.src('src/config/**/*.*', {base: 'src/'})
1616
.pipe(gulp.dest('lib'));
1717
})

0 commit comments

Comments
 (0)