# hlock

> #### 引用

Latest version **0.0.5** (published 2021-11-09) · ISC license · 0 weekly downloads

## Install

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

## 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.5 |
| Published | 2021-11-09 |
| First published | 2021-11-09 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 2 |
| Unpacked size | 11.4 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | eden |
| Maintainers | edenhuang |
| Keywords | module, hlock, encode, decode, cookie |

## Links

- npm: https://www.npmjs.com/package/hlock
- Repository: https://github.com/Eden-Kitty/learn-rollup
- Homepage: https://github.com/Eden-Kitty/learn-rollup#readme
- Issues: https://github.com/Eden-Kitty/learn-rollup/issues
- npm.io page: https://npm.io/package/hlock

## Dependencies (2)

- [js-base64](https://npm.io/package/js-base64.md) ^3.7.2
- [js-cookie](https://npm.io/package/js-cookie.md) ^3.0.1

## Alternatives

- [flatbuffers](https://npm.io/package/flatbuffers.md) — 6.0M weekly downloads
- [jwt-simple](https://npm.io/package/jwt-simple.md) — 259.5K weekly downloads
- [@exodus/patch-broken-hermes-typed-arrays](https://npm.io/package/@exodus/patch-broken-hermes-typed-arrays.md) — 28.5K weekly downloads
- [@native-to-anchor/buffer-layout](https://npm.io/package/@native-to-anchor/buffer-layout.md) — 12.2K weekly downloads
- [binary-parser-encoder](https://npm.io/package/binary-parser-encoder.md) — 5.3K weekly downloads

## Recent versions

- 0.0.5 (latest) — 2021-11-09
- 0.0.4 — 2021-11-09
- 0.0.3 — 2021-11-09
- 0.0.2 — 2021-11-09
- 0.0.1 — 2021-11-09

## README

#  HLock

#### 引用

```bash
npm install hlock --save

```

```js
const hLock = new HLock()
import hLock from 'HLock
```

#### Options

```
- key:cookie的key值
```

#### 例子

```js

- 普通加密解密

const a = hLock.encode('大鲨鱼!')

console.log(a)

console.log(hLock.decode(a))

console.log('******************************************************')

- 本地会种一个cookie

const b = hLock.encodeCookie('小小鱼！！！==')

console.log(b)

console.log(hLock.decodeCookie())

```

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