@leofcoin/chain 1.4.35 → 1.4.36

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/exports/node.js CHANGED
@@ -17,7 +17,8 @@ class Node {
17
17
  this.#node = globalThis.Peernet ? await new globalThis.Peernet(config, password) : await new Peernet(config, password);
18
18
  await nodeConfig(config);
19
19
  globalThis.pubsub.subscribe('chain:ready', () => {
20
- this.#node.start();
20
+ if (!this.#node.autoStart)
21
+ this.#node.start();
21
22
  });
22
23
  return this;
23
24
  // this.config = await config()
@@ -0,0 +1,10 @@
1
+ export default class Node {
2
+ #private;
3
+ constructor(config: any, password: string);
4
+ _init(config: {
5
+ network: string;
6
+ networkName: string;
7
+ networkVersion: string;
8
+ stars: any;
9
+ }, password: string): Promise<this>;
10
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@leofcoin/chain",
3
- "version": "1.4.35",
3
+ "version": "1.4.36",
4
4
  "description": "Official javascript implementation",
5
5
  "exports": {
6
6
  "./node": "./exports/node.js",
@@ -20,7 +20,7 @@
20
20
  "docs": "sh ./node_modules/.bin/esdoc src/chain.js",
21
21
  "workers": "cp ./../workers/src/** ./workers",
22
22
  "build": "npm run c",
23
- "demo": "jsproject --serve ./demo --port 5478 --open demo",
23
+ "demo": "jsproject --serve ./ --port 5478 --open demo",
24
24
  "test": "node --openssl-legacy-provider test",
25
25
  "pack": "webpack"
26
26
  },
@@ -33,7 +33,9 @@
33
33
  "author": "",
34
34
  "license": "MIT",
35
35
  "devDependencies": {
36
+ "@rollup/plugin-commonjs": "^24.0.1",
36
37
  "@rollup/plugin-json": "^6.0.0",
38
+ "@rollup/plugin-node-resolve": "^15.0.1",
37
39
  "@rollup/plugin-typescript": "^11.0.0",
38
40
  "@types/bs58check": "^2.1.0",
39
41
  "@types/pako": "^2.0.0",
@@ -54,8 +56,8 @@
54
56
  "@leofcoin/messages": "^1.2.0",
55
57
  "@leofcoin/multi-wallet": "^2.1.1",
56
58
  "@leofcoin/networks": "^1.0.0",
57
- "@leofcoin/peernet": "^1.0.0",
58
- "@leofcoin/peernet-swarm": "^0.5.12",
59
+ "@leofcoin/peernet": "^1.1.2",
60
+ "@leofcoin/peernet-swarm": "^1.0.0",
59
61
  "@leofcoin/storage": "^3.0.6",
60
62
  "@leofcoin/utils": "^1.1.4",
61
63
  "@leofcoin/workers": "^1.3.5",
@@ -63,7 +65,9 @@
63
65
  "@vandeurenglenn/easy-worker": "^1.0.2",
64
66
  "@vandeurenglenn/queue": "^1.0.0",
65
67
  "chalk": "^4.0.0",
66
- "pako": "^2.0.4"
68
+ "p2pt": "^1.5.1",
69
+ "pako": "^2.0.4",
70
+ "simple-peer": "^9.11.1"
67
71
  },
68
72
  "eslintConfig": {
69
73
  "env": {