# cool-local-storage

> 本地存储工具

Latest version **0.0.8** (published 2022-03-22) · ISC license · 0 weekly downloads

## Install

```sh
npm install cool-local-storage
pnpm add cool-local-storage
yarn add cool-local-storage
bun add cool-local-storage
```

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.8 |
| Published | 2022-03-22 |
| First published | 2022-03-21 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 3 |
| Unpacked size | 21.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | gaofeng |
| Maintainers | tsing_gaofeng |
| Keywords | localStorage, sessionStorage, cookie |

## Links

- npm: https://www.npmjs.com/package/cool-local-storage
- Repository: https://github.com/optyours/storage
- Homepage: https://github.com/optyours/storage#readme
- Issues: https://github.com/optyours/storage/issues
- npm.io page: https://npm.io/package/cool-local-storage

## Dependencies (3)

- [lodash](https://npm.io/package/lodash.md) ^4.17.21
- [crypto-js](https://npm.io/package/crypto-js.md) ^4.1.1
- [js-cookie](https://npm.io/package/js-cookie.md) ^3.0.1

## Alternatives

- [localforage](https://npm.io/package/localforage.md) — 6.2M weekly downloads
- [localforage-observable](https://npm.io/package/localforage-observable.md) — 30.8K weekly downloads
- [@y/y](https://npm.io/package/@y/y.md) — 30.1K weekly downloads
- [@metaobjectsdev/render](https://npm.io/package/@metaobjectsdev/render.md) — 3.5K weekly downloads
- [@ledgerhq/coin-algorand](https://npm.io/package/@ledgerhq/coin-algorand.md) — 1.1K weekly downloads

## Recent versions

- 0.0.8 (latest) — 2022-03-22
- 0.0.7 — 2022-03-22
- 0.0.6 — 2022-03-22
- 0.0.5 — 2022-03-22
- 0.0.4 — 2022-03-22
- 0.0.3 — 2022-03-22
- 0.0.2 — 2022-03-22
- 0.0.1 — 2022-03-22
- 0.0.0 — 2022-03-21

## README

# `storage`

> TODO: description

## Usage
## 使用localStorage

```
import {
  local, encryptionLocal, 
} from 'storage';

local.setStorage('storage', {name: 1});

encryptionLocal.setStorage('storage_encryption', {name: 2}) // 对存储的信息进行加密

```

## 使用sesssionStorage

```
import {
   sessionLocal, encryptionSessionLocal, 
} from 'storage';

sessionLocal.setStorage('storage', {name: 1});

encryptionSessionLocal.setStorage('storage_encryption', {name: 2}) // 对存储的信息进行加密

```
## 使用cookie


```
import {
  cookieLocal, encryptionCookieLocal
} from 'storage';

cookieLocal.setStorage('storage', {name: 1});
encryptionCookieLocal.setStorage('storage_encryption', {name: 2}) // 对存储的信息进行加密
```

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