mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2025-10-16 12:05:41 +00:00
20 lines
576 B
TypeScript
20 lines
576 B
TypeScript
// Type definitions for find-parent-dir 0.3
|
|
// Project: https://github.com/thlorenz/find-parent-dir
|
|
// Definitions by: Ika <https://github.com/ikatyang>
|
|
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
|
|
|
/**
|
|
* Finds the first parent directory that contains a given file or directory.
|
|
*/
|
|
declare function findParentDir(
|
|
currentFullPath: string,
|
|
clue: string,
|
|
cb: (err: any, dir: string | null) => void
|
|
): void;
|
|
|
|
declare namespace findParentDir {
|
|
function sync(currentFullPath: string, clue: string): string | null;
|
|
}
|
|
|
|
export = findParentDir;
|