# tildify

> Convert an absolute path to a tilde path: `/Users/sindresorhus/dev` → `~/dev`

Latest version **3.0.0** (published 2021-08-12) · MIT license · 0 weekly downloads

## Install

```sh
npm install tildify
pnpm add tildify
yarn add tildify
bun add tildify
```

## Health

**Score 28/100 (F)** — status: abandoned.

Positive: has types package; esm support; no vulnerabilities; high quality score.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 3.0.0 |
| Published | 2021-08-12 |
| First published | 2014-01-09 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | separate (@types/tildify) |
| Module format | ESM |
| Node | ^12.20.0 \|\| ^14.13.1 \|\| >=16.0.0 |
| Dependencies | 0 |
| Unpacked size | 2.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 95 |
| Author | Sindre Sorhus |
| Maintainers | sindresorhus |
| Keywords | unexpand, homedir, tilde, tildify, collapse, path, home, directory, user, expand, convert |

## Links

- npm: https://www.npmjs.com/package/tildify
- Repository: https://github.com/sindresorhus/tildify
- Homepage: https://github.com/sindresorhus/tildify#readme
- Issues: https://github.com/sindresorhus/tildify/issues
- Funding: https://github.com/sponsors/sindresorhus
- npm.io page: https://npm.io/package/tildify

## Alternatives

- [base64url](https://npm.io/package/base64url.md) — 6.1M weekly downloads
- [get-installed-path](https://npm.io/package/get-installed-path.md) — 502.9K weekly downloads
- [@uppy/url](https://npm.io/package/@uppy/url.md) — 185.8K weekly downloads
- [@d3fc/d3fc-shape](https://npm.io/package/@d3fc/d3fc-shape.md) — 16.2K weekly downloads
- [localizer](https://npm.io/package/localizer.md) — 226 weekly downloads

## Recent versions

- 3.0.0 (latest) — 2021-08-12
- 2.0.0 — 2019-04-29
- 1.2.0 — 2016-04-12
- 1.1.2 — 2015-10-04
- 1.1.1 — 2015-09-18
- 1.1.0 — 2015-06-13
- 1.0.0 — 2014-08-03
- 0.2.0 — 2014-04-07
- 0.1.0 — 2014-01-09

## README

# tildify

> Convert an absolute path to a tilde path: `/Users/sindresorhus/dev` → `~/dev`

## Install

```
$ npm install tildify
```

## Usage

```js
import tildify from 'tildify';

tildify('/Users/sindresorhus/dev');
//=> '~/dev'
```

## Related

See [untildify](https://github.com/sindresorhus/untildify) for the inverse.

---
_Source: https://npm.io/package/tildify · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
