UNPKG

335 BTypeScriptView Raw
1/**
2Check if a path is in the [current working directory](https://en.wikipedia.org/wiki/Working_directory).
3
4@example
5```
6import isPathInCwd from 'is-path-in-cwd';
7
8isPathInCwd('unicorn');
9//=> true
10
11isPathInCwd('../rainbow');
12//=> false
13
14isPathInCwd('.');
15//=> false
16```
17*/
18export default function isPathInCwd(path: string): boolean;