@wessberg/pathutil
TypeScript icon, indicating that this package has built-in type declarations

0.0.10 • Public • Published

PathUtil

NPM version License-mit

A helper class for working with paths.

Installation

Simply do: npm install @wessberg/pathutil.

Usage

const pathUtil = new PathUtil();
pathUtil.hasExtension("foo/bar.ts"); // true
pathUtil.clearExtension("foo/bar.ts"); // foo/bar
pathUtil.isLib("path"); // true
pathUtil.makeRelative("./foo/bar/baz.ts", "./foo/bar.ts"); // "../bar.ts"

Package Sidebar

Install

npm i @wessberg/pathutil

Weekly Downloads

10

Version

0.0.10

License

MIT

Unpacked Size

60.5 kB

Total Files

21

Last publish

Collaborators

  • wessberg