Skip to content

Commit 355fc4e

Browse files
es128phated
authored andcommitted
Fix: Set chokidar option ignoreIntial: true by default
1 parent 32abfe5 commit 355fc4e

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

index.js

+5-1
Original file line numberDiff line numberDiff line change
@@ -23,14 +23,18 @@ Gulp.prototype.watch = function(glob, opt, task) {
2323

2424
if (typeof opt === 'function') {
2525
task = opt;
26-
opt = null;
26+
opt = {};
2727
}
2828

2929
var fn;
3030
if (typeof task === 'function') {
3131
fn = this.parallel(task);
3232
}
3333

34+
if (opt.ignoreInitial == null) {
35+
opt.ignoreInitial = true;
36+
}
37+
3438
var watcher = chokidar.watch(glob, opt);
3539
if (fn) {
3640
watcher

0 commit comments

Comments
 (0)