path-depth
v1.0.0
Published
Get the depth of a file/URL path.
Downloads
8,732
Maintainers
Readme
path-depth
Get the depth of a file/URL path.
depth('/a/b/c') // 3
depth('a\\..\\b\\c') // 2
depth('a/./b') // 2
depth('foo/../..') // -1
depth('.') // 0
Installing
npm install path-depth
Contributing
If you have a question, found a bug or want to propose a feature, have a look at the issues page.