Page Contents
Home > @loopback/boot > discoverFiles
discoverFiles() function
Returns all files matching the given glob pattern relative to root
Signature:
export declare function discoverFiles(pattern: string, root: string): Promise<string[]>;
Parameters
Parameter | Type | Description |
---|---|---|
pattern | string | A glob pattern |
root | string | Root folder to start searching for matching files |
Returns:
Promise<string[]>
Array of discovered files