mirror of
https://github.com/wassname/DefinitelyTyped.git
synced 2026-09-24 13:00:46 +08:00
Improve gulp.watch()
This commit is contained in:
Vendored
+9
-33
@@ -236,45 +236,21 @@ declare module gulp {
|
||||
dest(outFolder:(file:string)=>string, opt?:IDestOptions): NodeJS.ReadWriteStream;
|
||||
|
||||
|
||||
/**
|
||||
* Watch files and do something when a file changes. This always returns an EventEmitter that emits change events.
|
||||
*
|
||||
* @param glob a single glob or array of globs that indicate which files to watch for changes.
|
||||
* @param tasks names of task(s) to run when a file changes, added with gulp.task()
|
||||
*/
|
||||
watch(glob:string, tasks:string[]): EventEmitter;
|
||||
watch(glob:string[], tasks:string[]): EventEmitter;
|
||||
|
||||
/**
|
||||
* Watch files and do something when a file changes. This always returns an EventEmitter that emits change events.
|
||||
*
|
||||
* @param glob a single glob or array of globs that indicate which files to watch for changes.
|
||||
* @param opt options, that are passed to the gaze library.
|
||||
* @param tasks names of task(s) to run when a file changes, added with gulp.task()
|
||||
* @param fn a callback or array of callbacks to be called on each change, or names of task(s) to run when a file changes, added with gulp.task().
|
||||
*/
|
||||
watch(glob:string, opt:IWatchOptions, tasks:string[]): EventEmitter;
|
||||
watch(glob:string[], opt:IWatchOptions, tasks:string[]): EventEmitter;
|
||||
|
||||
/**
|
||||
* Watch files and do something when a file changes. This always returns an EventEmitter that emits change events.
|
||||
*
|
||||
* @param glob a single glob or array of globs that indicate which files to watch for changes.
|
||||
* @param fn a callback or array of callbacks to be called on each change.
|
||||
*/
|
||||
watch(glob:string, fn:IWatchCallback): EventEmitter;
|
||||
watch(glob:string[], fn:IWatchCallback): EventEmitter;
|
||||
watch(glob:string, fn:IWatchCallback[]): EventEmitter;
|
||||
watch(glob:string[], fn:IWatchCallback[]): EventEmitter;
|
||||
|
||||
/**
|
||||
* Watch files and do something when a file changes. This always returns an EventEmitter that emits change events.
|
||||
*
|
||||
* @param glob a single glob or array of globs that indicate which files to watch for changes.
|
||||
* @param opt options, that are passed to the gaze library.
|
||||
* @param fn a callback or array of callbacks to be called on each change.
|
||||
*/
|
||||
watch(glob:string, opt:IWatchOptions, fn:IWatchCallback): EventEmitter;
|
||||
watch(glob:string, opt:IWatchOptions, fn:IWatchCallback[]): EventEmitter;
|
||||
watch(glob:string, fn:(IWatchCallback|string)): EventEmitter;
|
||||
watch(glob:string, fn:(IWatchCallback|string)[]): EventEmitter;
|
||||
watch(glob:string, opt:IWatchOptions, fn:(IWatchCallback|string)): EventEmitter;
|
||||
watch(glob:string, opt:IWatchOptions, fn:(IWatchCallback|string)[]): EventEmitter;
|
||||
watch(glob:string[], fn:(IWatchCallback|string)): EventEmitter;
|
||||
watch(glob:string[], fn:(IWatchCallback|string)[]): EventEmitter;
|
||||
watch(glob:string[], opt:IWatchOptions, fn:(IWatchCallback|string)): EventEmitter;
|
||||
watch(glob:string[], opt:IWatchOptions, fn:(IWatchCallback|string)[]): EventEmitter;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user