feat: Deno.fsEvents() (#3452)

This commit is contained in:
Bartek Iwańczuk 2020-02-21 13:21:51 -05:00 committed by GitHub
parent 754b8c65ad
commit bd640bc7e6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 1355 additions and 943 deletions

View file

@ -1620,6 +1620,21 @@ declare namespace Deno {
*/
export function resources(): ResourceMap;
/** UNSTABLE: new API. Needs docs. */
export interface FsEvent {
kind: "any" | "access" | "create" | "modify" | "remove";
paths: string[];
}
/** UNSTABLE: new API. Needs docs.
*
* recursive option is true by default.
*/
export function fsEvents(
paths: string | string[],
options?: { recursive: boolean }
): AsyncIterableIterator<FsEvent>;
/** How to handle subprocess stdio.
*
* "inherit" The default if unspecified. The child inherits from the