]> git.wincent.com - hextrapolate.git/commitdiff
Make `gulp watch` monitor CSS changes as well
authorGreg Hurrell <greg@hurrell.net>
Tue, 4 Aug 2015 08:27:22 +0000 (01:27 -0700)
committerGreg Hurrell <greg@hurrell.net>
Tue, 4 Aug 2015 08:27:22 +0000 (01:27 -0700)
Seeing as CSS is getting bundled via webpack, we should really be
triggering the webpack:build task whenever it changes.

Got rid of the misleading "js" task in the process.

gulpfile.babel.js

index 96a22f923c8bcb8b6d2ae19d9ec2bc6ad6856a32..f5e775bdb87e0236ae0df18e412162ac87599fbc 100644 (file)
@@ -46,8 +46,6 @@ gulp.task('build', ['webpack:build']);
 
 gulp.task('flow', ['typecheck']);
 
-gulp.task('js', ['build', 'lint', 'test', 'typecheck']);
-
 gulp.task('lint', () => (
   gulp.src('src/**/*.js')
     .pipe(eslint())
@@ -79,7 +77,7 @@ gulp.task('test', () => (
 
 gulp.task('watch', () => {
   watching = true;
-  gulp.watch('src/**/*.js', ['js']);
+  gulp.watch('src/**/*.{css,js}', ['build', 'lint', 'test', 'typecheck']);
 });
 
 gulp.task('webpack:build', callback => {