@0xpolygonid/js-sdk 1.0.0-beta.7 → 1.0.0-beta.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +23 -5
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Polygon ID JS SDK
|
|
2
2
|
|
|
3
|
-
SDK to work with Polygon ID using JavaScript and TypeScript languages.
|
|
3
|
+
SDK to work with Polygon ID using JavaScript and TypeScript languages.
|
|
4
4
|
|
|
5
5
|
## Disclaimer
|
|
6
6
|
|
|
@@ -11,7 +11,7 @@ We provide limited support for it and would love to hear your feedback.
|
|
|
11
11
|
|
|
12
12
|
Installation:
|
|
13
13
|
|
|
14
|
-
```
|
|
14
|
+
```bash
|
|
15
15
|
npm install @0xpolygonid/js-sdk
|
|
16
16
|
```
|
|
17
17
|
|
|
@@ -20,14 +20,16 @@ See [tests](/tests) for examples on how to use SDK.
|
|
|
20
20
|
## Tests
|
|
21
21
|
|
|
22
22
|
Run unit tests:
|
|
23
|
-
|
|
23
|
+
|
|
24
|
+
```bash
|
|
24
25
|
npm run test
|
|
25
26
|
```
|
|
26
27
|
|
|
27
28
|
Note: mtp / sig / auth / rhs files contain integration tests!
|
|
28
29
|
|
|
29
30
|
To run them, please set following variables:
|
|
30
|
-
|
|
31
|
+
|
|
32
|
+
```bash
|
|
31
33
|
export WALLET_KEY="...key in hex format"
|
|
32
34
|
export RPC_URL="...url to polygon network rpc node"
|
|
33
35
|
export RHS_URL="..reverse hash service url"
|
|
@@ -37,4 +39,20 @@ And place actual circuits to `test/proofs/testdata`
|
|
|
37
39
|
|
|
38
40
|
## Documentation
|
|
39
41
|
|
|
40
|
-
|
|
42
|
+
### Generate documentation
|
|
43
|
+
|
|
44
|
+
1. Define path where documentation repository is located, for example:
|
|
45
|
+
|
|
46
|
+
```typescript
|
|
47
|
+
const DOCS_DIR = '../js-sdk-tutorials/docs/api';
|
|
48
|
+
```
|
|
49
|
+
|
|
50
|
+
2. ```bash
|
|
51
|
+
npm run tsc:declaration:watch
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
3. ```bash
|
|
55
|
+
npm run doc:watch:website
|
|
56
|
+
```
|
|
57
|
+
|
|
58
|
+
Documentation can be found [here](https://0xpolygonid.github.io/js-sdk-tutorials/)
|
package/package.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@0xpolygonid/js-sdk",
|
|
3
|
-
"version": "1.0.0-beta.
|
|
3
|
+
"version": "1.0.0-beta.8",
|
|
4
4
|
"description": "SDK to work with Polygon ID",
|
|
5
5
|
"main": "dist/cjs/index.js",
|
|
6
|
-
"module": "dist/
|
|
6
|
+
"module": "dist/esm_esbuild/index.js",
|
|
7
7
|
"source": "./src/index.ts",
|
|
8
8
|
"esm:esbuild": "dist/esm_esbuild/index.js",
|
|
9
9
|
"typings": "dist/types/index.d.ts",
|