# strip-path

> Strip a path from a path

Latest version **2.0.0** (published 2021-08-18) · MIT license · 0 weekly downloads

## Install

```sh
npm install strip-path
pnpm add strip-path
yarn add strip-path
bun add strip-path
```

## Health

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

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.0.0 |
| Published | 2021-08-18 |
| First published | 2014-02-28 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM |
| Node | ^12.20.0 \|\| ^14.13.1 \|\| >=16.0.0 |
| Dependencies | 0 |
| Unpacked size | 2.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 18 |
| Author | Sindre Sorhus |
| Maintainers | sindresorhus |
| Keywords | path, directory, file, strip, trim, normalize, string |

## Links

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

## 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
- [@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
- [tg-resolve](https://npm.io/package/tg-resolve.md) — 176 weekly downloads

## Recent versions

- 2.0.0 (latest) — 2021-08-18
- 1.0.0 — 2014-08-13
- 0.1.1 — 2014-03-06
- 0.1.0 — 2014-02-28

## README

# strip-path

> Strip a path from a path

## Install

```
$ npm install strip-path
```

## Usage

```js
import stripPath from 'strip-path';

stripPath('path1/path2/path3/path4', 'path1/path2');
//=> 'path3/path4'
```

## API

### stripPath(path, stripPath)

#### path

*Required*\
Type: `string`  

The path to stripped.

#### stripPath

*Required*\
Type: `string`  

The path to strip from `path`.

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