Updated Home (markdown)
parent
da89c1439c
commit
67afb3cf55
16
Home.md
16
Home.md
@ -4,24 +4,16 @@
|
|||||||
|
|
||||||
## 安装
|
## 安装
|
||||||
|
|
||||||
1. 建立一个只有 `package:read` 权限的 PAT Token:
|
```bash
|
||||||
2. 设定 [`~/.npmrc`][npmrc],加入下述内容并替换 `<刚申请的 PAT>` 为刚申请的 Token 值(如 `ghp_ABCDEF0123456789`):
|
npm i --save @unlock-music-gh/joox-crypto
|
||||||
|
```
|
||||||
```ini
|
|
||||||
//npm.pkg.github.com/:_authToken=<刚申请的 PAT>
|
|
||||||
@unlock-music:registry=https://npm.pkg.github.com
|
|
||||||
```
|
|
||||||
|
|
||||||
3. 安装依赖 `npm i --save @unlock-music/joox-crypto`;
|
|
||||||
|
|
||||||
注:使用 GitHub Actions 构建时应该[不需要提供 auth token][ref_workflow]。
|
|
||||||
|
|
||||||
## 使用
|
## 使用
|
||||||
|
|
||||||
参考 [`joox-decrypt`][ref_source]。
|
参考 [`joox-decrypt`][ref_source]。
|
||||||
|
|
||||||
```js
|
```js
|
||||||
const jooxFactory = require('@unlock-music/joox-crypto');
|
const jooxFactory = require('@unlock-music-gh/joox-crypto');
|
||||||
|
|
||||||
const data = new Uint8Array(...);
|
const data = new Uint8Array(...);
|
||||||
const decryptor = jooxFactory(data, '00000000000000000000000000000000');
|
const decryptor = jooxFactory(data, '00000000000000000000000000000000');
|
||||||
|
Loading…
Reference in New Issue
Block a user