Commit 77ab8ece authored by rockyl's avatar rockyl

优化自动编译和刷新的机制

parent c4c30082
...@@ -125,7 +125,7 @@ gulp.task('compileTs', async function () { ...@@ -125,7 +125,7 @@ gulp.task('compileTs', async function () {
}); });
gulp.task('reload', function () { gulp.task('reload', function () {
gulp.src(['debug/**/*.js']) gulp.src(['debug/**/*.js', 'assets/**/*.+(scene|pfb)'])
.pipe(livereload()); .pipe(livereload());
}); });
...@@ -133,7 +133,7 @@ gulp.task('watch', function () { ...@@ -133,7 +133,7 @@ gulp.task('watch', function () {
livereload.listen({ livereload.listen({
quiet: true, quiet: true,
}); });
gulp.watch(['src/**/*.+(ts|js)', 'assets/**/*.+(ts|scene|pfb)'], ['compile']); gulp.watch(['src/**/*.+(ts|js)', 'assets/**/*.+(ts)'], ['compile']);
}); });
gulp.task('dev', ['compile', 'watch'], function (cb) { gulp.task('dev', ['compile', 'watch'], function (cb) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment