@cjser/tildify
v3.0.0-cjser.2
Published
Convert an absolute path to a tilde path: `/Users/sindresorhus/dev` → `~/dev`
Maintainers
Readme
tildify
Convert an absolute path to a tilde path:
/Users/sindresorhus/dev→~/dev
Install
$ npm install tildifyUsage
import tildify from 'tildify';
tildify('/Users/sindresorhus/dev');
//=> '~/dev'Related
See untildify for the inverse.
cjser
This package is a CommonJS-compatible build generated by cjser for projects that still need require() support. The source version matches the original npm package version, with a cjser prerelease suffix for this generated build.
Original repository: https://github.com/sindresorhus/tildify
