UNPKG

611 BTypeScriptView Raw
1export = commondir;
2
3/**
4 * Compute the closest common parent directory for an array absolutePaths.
5 *
6 * @see \`{@link https://github.com/substack/node-commondir#commondirabsolutepaths }\`
7 */
8declare function commondir(basedir: string, relativePaths: string[]): string;
9/**
10 * Compute the closest common parent directory for an array relativePaths which will be resolved for each dir in
11 * relativePaths according to: path.resolve(basedir, dir).
12 *
13 * @see \`{@link https://github.com/substack/node-commondir#commondirbasedir-relativepaths }\`
14 */
15declare function commondir(absolutePaths: string[]): string;