10 examples of 'gulp watch examples' in JavaScript

Every line of 'gulp watch examples' code snippets is scanned for vulnerabilities by our powerful machine learning engine that combs millions of open source libraries, ensuring your JavaScript code is secure.

All examples are scanned by Snyk Code

By copying the Snyk Code Snippets you agree to
this disclaimer
100gulp.task('watch', function watch() {
101 gulp.watch(cfg.gulp.all, ['compile', 'vendorify']);
102});
Important

Use secure code every time

Secure your code as it's written. Use Snyk Code to scan source code in minutes – no build needed – and fix issues immediately. Enable Snyk Code

58const watch = function watch() {
59 gulp.watch(paths.watch.sass, styles)
60}
89function watch() {
90 return gulp.watch(['src/**/*.ts', 'src/ui/*.html', 'test/**/*.ts'],
91 gulp.series(copyHtmlTemplates, lint, testNoFail, compile));
92}
56gulp.task('watch', ['test'], function watch() {
57 gulp.watch([allOfMyFiles, allOfMyTestFiles], ['test']);
58});
58gulp.task('watch', function watch() {
59 gulp.watch('components/*.js', ['build']);
60});
52export function watch() {
53 watching = true;
54 return gulp.watch('src/**/*.js', babel);
55}
11function watch() {
12 gulp.watch([PATHS.srcDir + 'pug/**/*.pug'], { interval: 500 }, gulp.series(taskPug));
13 gulp.watch([PATHS.srcDir + 'js/**/*.js'], { interval: 500 }, gulp.series(taskWatchify));
14 gulp.watch([PATHS.srcDir + 'css/**/*.css'], { interval: 500 }, gulp.series(postcssWithStream));
15}
181function watch() {
182 gulp.watch([
183 'src/**/*.js',
184 'tests/**/*.spec.js'
185 ], gulp.series(lint, test, buildJs));
186}
62export function watch() {
63 gulp.watch(settings.sources.scripts, gulp.series(gulp.parallel(lint, reload))).on('change', informOnChange);
64 gulp.watch(settings.sources.styles, gulp.series(styles, gulp.parallel(lintStyles, reload))).on('change', informOnChange);
65
66 if (useHandlebars) {
67 gulp.watch([
68 ...settings.sources.handlebars,
69 './src/handlebars/layouts/*.hbs',
70 './src/handlebars/partials/**/*.hbs',
71 './src/handlebars/helpers/*.js'
72 ], gulp.series(handlebars, gulp.parallel(lintBootstrap, validateHtml, gulp.series(processHtml, reload)))).on('change', informOnChange);
73 gulp.watch(['./src/handlebars/helpers/*.js'], gulp.parallel(lint)).on('change', informOnChange);
74 } else {
75 gulp.watch(settings.sources.html, gulp.parallel(lintBootstrap, validateHtml, gulp.series(processHtml, reload))).on('change', informOnChange);
76 }
77
78 gulp.watch(settings.sources.images, gulp.series(images, reload)).on('change', informOnChange);
79 gulp.watch(settings.sources.fonts, gulp.series(fonts, reload)).on('change', informOnChange);
80 gulp.watch(settings.sources.appTemplates, gulp.series(appTemplates, reload)).on('change', informOnChange);
81
82 function informOnChange(path) {
83 gutil.log(`File ${chalk.yellow(path)} has changed`);
84 }
85}
27function watch(done) {
28 gulp.watch(conf.path.src('demo/**/*.html'), reloadBrowserSync);
29 done();
30}

Related snippets