# persist-path

> Get OS-specific path to store persistent data

Latest version **1.0.2** (published 2017-06-12) · MIT license · 0 weekly downloads

## Install

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

## Health

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

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.2 |
| Published | 2017-06-12 |
| First published | 2016-08-30 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 9 |
| Author | Sebastian Raff https://github.com/hobbyquaker |
| Maintainers | hobbyquaker |
| Keywords | persist, path, store, storage, save, data, json, user, appdata, library |

## Links

- npm: https://www.npmjs.com/package/persist-path
- Repository: https://github.com/hobbyquaker/persist-path
- Issues: https://github.com/hobbyquaker/persist-path/issues
- npm.io page: https://npm.io/package/persist-path

## Alternatives

- [@mapbox/jsonlint-lines-primitives](https://npm.io/package/@mapbox/jsonlint-lines-primitives.md) — 5.3M weekly downloads
- [reftools](https://npm.io/package/reftools.md) — 3.5M weekly downloads
- [@hey-api/openapi-ts](https://npm.io/package/@hey-api/openapi-ts.md) — 3.5M weekly downloads
- [@mapbox/geojson-rewind](https://npm.io/package/@mapbox/geojson-rewind.md) — 2.4M weekly downloads
- [turbo-stream](https://npm.io/package/turbo-stream.md) — 1.7M weekly downloads

## Recent versions

- 1.0.2 (latest) — 2017-06-12
- 1.0.1 — 2016-08-30
- 1.0.0 — 2016-08-30

## README

# persist-path

[![NPM version](https://badge.fury.io/js/persist-path.svg)](http://badge.fury.io/js/persist-path)
[![Dependency Status](https://img.shields.io/gemnasium/hobbyquaker/persist-path.svg?maxAge=2592000)](https://gemnasium.com/github.com/hobbyquaker/persist-path)
[![XO code style](https://img.shields.io/badge/code_style-XO-5ed9c7.svg)](https://github.com/sindresorhus/xo)
[![License][mit-badge]][mit-url]

> Get OS-specific path to store persistent data

## Usage

```npm install persist-path```

```Javascript
var ppath = require('persist-path')();
```

## OS-specific Paths

### Linux/BSD

If you supply an argument to the required function call this will be appended as .dot directory.

Example:
```Javascript
var ppath = require('persist-path')('myproject/settings');

console.log(ppath); // /home/<username>/.myproject/settings
```

### macOS

If you supply an argument to the required function call this will be appended on Library/Preferences in the Users home

Example:
```Javascript
var ppath = require('persist-path')('myproject/settings');

console.log(ppath); // /Users/<username>/Library/Preferences/myproject/settings
```

### Windows

If you supply an argument to the required function call this will be appended on Users %appdata% dir

# License

MIT (c) 2016 [Sebastian Raff](https://github.com/hobbyquaker)

[mit-badge]: https://img.shields.io/badge/License-MIT-blue.svg?style=flat
[mit-url]: LICENSE

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