XuelesszzZ 94af2b8e7b 6-30-5 | 1 anno fa | |
---|---|---|
.. | ||
index.d.ts | 1 anno fa | |
index.js | 1 anno fa | |
license | 1 anno fa | |
package.json | 1 anno fa | |
readme.md | 1 anno fa |
Check if a path is inside another path
$ npm install is-path-inside
const isPathInside = require('is-path-inside');
isPathInside('a/b/c', 'a/b');
//=> true
isPathInside('a/b/c', 'x/y');
//=> false
isPathInside('a/b/c', 'a/b/c');
//=> false
isPathInside('/Users/sindresorhus/dev/unicorn', '/Users/sindresorhus');
//=> true
MIT © Sindre Sorhus