Advertisement
Guest User

Untitled

a guest
Feb 7th, 2016
45
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.36 KB | None | 0 0
  1. import gulp from 'gulp'
  2.  
  3. gulp.task('compile:watch', (done) => {
  4. let watcher = gulp.watch('src/**/*.js');
  5. watcher.on('change', () => {
  6. gulp.src('src/**/*.js')
  7. .pipe(gulp.dest('dist'));
  8. });
  9. done();
  10. });
  11.  
  12. gulp.task('callback', () => {
  13. console.log('hi!');
  14. });
  15.  
  16. gulp.task('serve', ['compile:watch'], () => {
  17. gulp.watch('dist/**/*.js', ['callback']);
  18. });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement