@eosrio/node-abieos 4.0.0-2039717 → 4.0.2-2039717

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/dist/abieos.js CHANGED
@@ -1,225 +1,230 @@
1
- // lib/abieos.ts
2
- import { createRequire } from "module";
3
- var abieos = createRequire(import.meta.url)("./abieos.node");
4
- var Abieos = class _Abieos {
5
- static logTag = "[node-abieos]";
6
- static instance;
7
- static native;
8
- static loadedContracts = /* @__PURE__ */ new Map();
9
- static debug = false;
10
- /**
11
- * Private constructor to enforce the Singleton pattern.
12
- * Throws an error if an attempt is made to create a second instance.
13
- */
14
- constructor() {
15
- if (_Abieos.instance) {
16
- throw new Error(`${_Abieos.logTag} Abieos is a Singleton class. Use Abieos.getInstance() to get the instance.`);
17
- }
18
- _Abieos.native = abieos;
19
- }
20
- /**
21
- * Returns the singleton instance of the Abieos class.
22
- * If an instance does not already exist, it creates one.
23
- * @returns {Abieos} The singleton instance of Abieos.
24
- */
25
- static getInstance() {
26
- if (!_Abieos.instance) {
27
- _Abieos.instance = new _Abieos();
28
- }
29
- return _Abieos.instance;
30
- }
31
- getLoadedAbis() {
32
- return Array.from(_Abieos.loadedContracts.keys());
33
- }
34
- /**
35
- * Cleans up all loaded contracts by deleting them from the native context.
36
- * This is useful for freeing up resources and ensuring a clean state.
37
- */
38
- cleanup() {
39
- _Abieos.loadedContracts.forEach((_, contractName) => {
40
- try {
41
- if (_Abieos.debug) {
42
- console.log(`${_Abieos.logTag} Cleaning up contract '${contractName}'...`);
43
- }
44
- _Abieos.native.delete_contract(contractName);
45
- _Abieos.loadedContracts.delete(contractName);
46
- } catch (e) {
47
- console.error(`${_Abieos.logTag} Failed to delete contract '${contractName}' during cleanup: ${e.message}`);
48
- }
49
- });
50
- }
51
- /**
52
- * Converts a string name to its corresponding 64-bit unsigned integer representation (BigInt).
53
- * @param {string} nameString The string name to convert.
54
- * @returns {BigInt} The BigInt representation of the name.
55
- */
56
- stringToName(nameString) {
57
- try {
58
- return _Abieos.native.string_to_name(nameString);
59
- } catch (e) {
60
- throw new Error(`${_Abieos.logTag} Failed to convert string to name '${nameString}': ${e.message}`);
61
- }
62
- }
63
- /**
64
- * Converts a JSON string or object to its hexadecimal binary representation.
65
- * @param {string} contractName The name of the contract.
66
- * @param {string} type The type within the ABI to use for conversion.
67
- * @param {string | object} json The JSON data as a string or object.
68
- * @returns {string} The hexadecimal string representation of the binary data.
69
- * @throws {Error} If parsing fails or an error occurs in the native module.
70
- */
71
- jsonToHex(contractName, type, json) {
72
- const jsonData = typeof json === "object" ? JSON.stringify(json) : json;
73
- try {
74
- return _Abieos.native.json_to_hex(contractName, type, jsonData);
75
- } catch (e) {
76
- throw new Error(`${_Abieos.logTag} Failed to convert JSON to hex for contract '${contractName}', type '${type}': ${e.message}`);
77
- }
78
- }
79
- /**
80
- * Converts a hexadecimal binary string to its JSON representation.
81
- * @param {string} contractName The name of the contract.
82
- * @param {string} type The type within the ABI to use for conversion.
83
- * @param {string} hex The hexadecimal string to convert.
84
- * @returns {any} The parsed JSON object.
85
- * @throws {Error} If parsing fails or an error occurs in the native module.
86
- */
87
- hexToJson(contractName, type, hex) {
88
- try {
89
- const data = _Abieos.native.hex_to_json(contractName, type, hex);
90
- try {
91
- return JSON.parse(data);
92
- } catch (parseError) {
93
- throw new Error(`${_Abieos.logTag} Failed to parse JSON string from hex for contract '${contractName}', type '${type}'. Received: ${data}. Parse error: ${parseError.message}`);
94
- }
95
- } catch (e) {
96
- throw new Error(`${_Abieos.logTag} Native error when converting hex to JSON for contract '${contractName}', type '${type}': ${e.message}`);
97
- }
98
- }
99
- /**
100
- * Converts a binary buffer to its JSON representation.
101
- * @param {string} contractName The name of the contract.
102
- * @param {string} type The type within the ABI to use for conversion.
103
- * @param {Buffer} buffer The binary data as a Buffer.
104
- * @returns {any} The parsed JSON object.
105
- * @throws {Error} If parsing fails or an error occurs in the native module.
106
- */
107
- binToJson(contractName, type, buffer) {
108
- try {
109
- const data = _Abieos.native.bin_to_json(contractName, type, buffer);
110
- try {
111
- return JSON.parse(data);
112
- } catch (parseError) {
113
- throw new Error(`${_Abieos.logTag} Failed to parse JSON string from binary for contract '${contractName}', type '${type}'. Received: ${data}. Parse error: ${parseError.message}`);
114
- }
115
- } catch (e) {
116
- throw new Error(`${_Abieos.logTag} Native error when converting binary to JSON for contract '${contractName}', type '${type}': ${e.message}`);
117
- }
118
- }
119
- /**
120
- * Loads an ABI for a given contract.
121
- * @param {string} contractName The name of the contract for which to load the ABI.
122
- * @param {string | object} abi The ABI as a JSON string or object.
123
- * @returns {boolean} True if the ABI was loaded successfully, false otherwise.
124
- * @throws {Error} If the ABI format is invalid or loading fails.
125
- */
126
- loadAbi(contractName, abi) {
127
- if (_Abieos.debug && _Abieos.loadedContracts.has(contractName)) {
128
- console.info(`${_Abieos.logTag} Contract '${contractName}' is already loaded. Updating ABI...`);
129
- }
130
- const abiString = typeof abi === "object" ? JSON.stringify(abi) : abi;
131
- if (typeof abiString !== "string") {
132
- throw new Error(`${_Abieos.logTag} ABI must be a String or Object.`);
133
- }
134
- try {
135
- const loaded = _Abieos.native.load_abi(contractName, abiString);
136
- if (loaded) {
137
- _Abieos.loadedContracts.set(contractName, Date.now());
138
- if (_Abieos.debug) {
139
- console.log(`${_Abieos.logTag} Loaded ABI for contract '${contractName}'.`);
140
- }
141
- }
142
- return loaded;
143
- } catch (e) {
144
- throw new Error(`${_Abieos.logTag} Failed to load ABI for contract '${contractName}': ${e.message}`);
145
- }
146
- }
147
- /**
148
- * Loads an ABI for a given contract from its hexadecimal representation.
149
- * @param {string} contractName The name of the contract for which to load the ABI.
150
- * @param {string} abihex The ABI as a hexadecimal string.
151
- * @returns {boolean} True if the ABI was loaded successfully, false otherwise.
152
- * @throws {Error} If loading fails.
153
- */
154
- loadAbiHex(contractName, abihex) {
155
- if (typeof abihex !== "string") {
156
- throw new Error(`${_Abieos.logTag} ABI hex must be a String.`);
157
- }
158
- if (_Abieos.debug && _Abieos.loadedContracts.has(contractName)) {
159
- console.info(`${_Abieos.logTag} Contract '${contractName}' is already loaded. Updating ABI...`);
160
- }
161
- try {
162
- const loaded = _Abieos.native.load_abi_hex(contractName, abihex);
163
- if (loaded) {
164
- _Abieos.loadedContracts.set(contractName, Date.now());
165
- if (_Abieos.debug) {
166
- console.log(`${_Abieos.logTag} Loaded ABI hex for contract '${contractName}'.`);
167
- }
168
- }
169
- return loaded;
170
- } catch (e) {
171
- throw new Error(`${_Abieos.logTag} Failed to load ABI hex for contract '${contractName}': ${e.message}`);
172
- }
173
- }
174
- /**
175
- * Retrieves the type name for a specific action within a contract's ABI.
176
- * @param {string} contractName The name of the contract.
177
- * @param {string} actionName The name of the action.
178
- * @returns {string} The type name associated with the action.
179
- * @throws {Error} If the contract or action is not found or another error occurs.
180
- */
181
- getTypeForAction(contractName, actionName) {
182
- try {
183
- return _Abieos.native.get_type_for_action(contractName, actionName);
184
- } catch (e) {
185
- throw new Error(`${_Abieos.logTag} Failed to get type for action '${actionName}' in contract '${contractName}': ${e.message}`);
186
- }
187
- }
188
- /**
189
- * Retrieves the type name for a specific table within a contract's ABI.
190
- * @param {string} contractName The name of the contract.
191
- * @param {string} table_name The name of the table.
192
- * @returns {string} The type name associated with the table.
193
- * @throws {Error} If the contract or table is not found or another error occurs.
194
- */
195
- getTypeForTable(contractName, table_name) {
196
- try {
197
- return _Abieos.native.get_type_for_table(contractName, table_name);
198
- } catch (e) {
199
- throw new Error(`${_Abieos.logTag} Failed to get type for table '${table_name}' in contract '${contractName}': ${e.message}`);
200
- }
201
- }
202
- /**
203
- * Deletes a contract's ABI from the abieos context.
204
- * @param {string} contractName The name of the contract to delete.
205
- * @returns {boolean} True if the contract was successfully deleted, false otherwise.
206
- * @throws {Error} If deletion fails.
207
- */
208
- deleteContract(contractName) {
209
- try {
210
- const deleted = _Abieos.native.delete_contract(contractName);
211
- if (deleted) {
212
- _Abieos.loadedContracts.delete(contractName);
213
- if (_Abieos.debug) {
214
- console.log(`${_Abieos.logTag} Deleted contract '${contractName}' from abieos context.`);
215
- }
216
- }
217
- return deleted;
218
- } catch (e) {
219
- throw new Error(`${_Abieos.logTag} Failed to delete contract '${contractName}': ${e.message}`);
220
- }
221
- }
222
- };
223
- export {
224
- Abieos
225
- };
1
+ // lib/abieos.ts
2
+ import { createRequire } from "module";
3
+ var abieos = createRequire(import.meta.url)("./abieos.node");
4
+ var Abieos = class _Abieos {
5
+ static logTag = "[node-abieos]";
6
+ static instance;
7
+ static native;
8
+ static loadedContracts = /* @__PURE__ */ new Map();
9
+ static debug = false;
10
+ /**
11
+ * Private constructor to enforce the Singleton pattern.
12
+ * Throws an error if an attempt is made to create a second instance.
13
+ */
14
+ constructor() {
15
+ if (_Abieos.instance) {
16
+ throw new Error(`${_Abieos.logTag} Abieos is a Singleton class. Use Abieos.getInstance() to get the instance.`);
17
+ }
18
+ _Abieos.native = abieos;
19
+ }
20
+ /**
21
+ * Returns the singleton instance of the Abieos class.
22
+ * If an instance does not already exist, it creates one.
23
+ * @returns {Abieos} The singleton instance of Abieos.
24
+ */
25
+ static getInstance() {
26
+ if (!_Abieos.instance) {
27
+ _Abieos.instance = new _Abieos();
28
+ }
29
+ return _Abieos.instance;
30
+ }
31
+ getLoadedAbis() {
32
+ return Array.from(_Abieos.loadedContracts.keys());
33
+ }
34
+ /**
35
+ * Cleans up all loaded contracts by deleting them from the native context.
36
+ * This is useful for freeing up resources and ensuring a clean state.
37
+ */
38
+ cleanup() {
39
+ const errors = [];
40
+ _Abieos.loadedContracts.forEach((_, contractName) => {
41
+ try {
42
+ if (_Abieos.debug) {
43
+ console.log(`${_Abieos.logTag} Cleaning up contract '${contractName}'...`);
44
+ }
45
+ _Abieos.native.delete_contract(contractName);
46
+ _Abieos.loadedContracts.delete(contractName);
47
+ } catch (e) {
48
+ errors.push({ contractName, error: e.message });
49
+ console.error(`${_Abieos.logTag} Failed to delete contract '${contractName}' during cleanup: ${e.message}`);
50
+ }
51
+ });
52
+ if (errors.length > 0) {
53
+ throw new Error(`${_Abieos.logTag} Errors during cleanup: ${JSON.stringify(errors)}`);
54
+ }
55
+ }
56
+ /**
57
+ * Converts a string name to its corresponding 64-bit unsigned integer representation (BigInt).
58
+ * @param {string} nameString The string name to convert.
59
+ * @returns {BigInt} The BigInt representation of the name.
60
+ */
61
+ stringToName(nameString) {
62
+ try {
63
+ return _Abieos.native.string_to_name(nameString);
64
+ } catch (e) {
65
+ throw new Error(`${_Abieos.logTag} Failed to convert string to name '${nameString}': ${e.message}`);
66
+ }
67
+ }
68
+ /**
69
+ * Converts a JSON string or object to its hexadecimal binary representation.
70
+ * @param {string} contractName The name of the contract.
71
+ * @param {string} type The type within the ABI to use for conversion.
72
+ * @param {string | object} json The JSON data as a string or object.
73
+ * @returns {string} The hexadecimal string representation of the binary data.
74
+ * @throws {Error} If parsing fails or an error occurs in the native module.
75
+ */
76
+ jsonToHex(contractName, type, json) {
77
+ const jsonData = typeof json === "object" ? JSON.stringify(json) : json;
78
+ try {
79
+ return _Abieos.native.json_to_hex(contractName, type, jsonData);
80
+ } catch (e) {
81
+ throw new Error(`${_Abieos.logTag} Failed to convert JSON to hex for contract '${contractName}', type '${type}': ${e.message}`);
82
+ }
83
+ }
84
+ /**
85
+ * Converts a hexadecimal binary string to its JSON representation.
86
+ * @param {string} contractName The name of the contract.
87
+ * @param {string} type The type within the ABI to use for conversion.
88
+ * @param {string} hex The hexadecimal string to convert.
89
+ * @returns {any} The parsed JSON object.
90
+ * @throws {Error} If parsing fails or an error occurs in the native module.
91
+ */
92
+ hexToJson(contractName, type, hex) {
93
+ try {
94
+ const data = _Abieos.native.hex_to_json(contractName, type, hex);
95
+ try {
96
+ return JSON.parse(data);
97
+ } catch (parseError) {
98
+ throw new Error(`${_Abieos.logTag} Failed to parse JSON string from hex for contract '${contractName}', type '${type}'. Received: ${data}. Parse error: ${parseError.message}`);
99
+ }
100
+ } catch (e) {
101
+ throw new Error(`${_Abieos.logTag} Native error when converting hex to JSON for contract '${contractName}', type '${type}': ${e.message}`);
102
+ }
103
+ }
104
+ /**
105
+ * Converts a binary buffer to its JSON representation.
106
+ * @param {string} contractName The name of the contract.
107
+ * @param {string} type The type within the ABI to use for conversion.
108
+ * @param {Buffer} buffer The binary data as a Buffer.
109
+ * @returns {any} The parsed JSON object.
110
+ * @throws {Error} If parsing fails or an error occurs in the native module.
111
+ */
112
+ binToJson(contractName, type, buffer) {
113
+ try {
114
+ const data = _Abieos.native.bin_to_json(contractName, type, buffer);
115
+ try {
116
+ return JSON.parse(data);
117
+ } catch (parseError) {
118
+ throw new Error(`${_Abieos.logTag} Failed to parse JSON string from binary for contract '${contractName}', type '${type}'. Received: ${data}. Parse error: ${parseError.message}`);
119
+ }
120
+ } catch (e) {
121
+ throw new Error(`${_Abieos.logTag} Native error when converting binary to JSON for contract '${contractName}', type '${type}': ${e.message}`);
122
+ }
123
+ }
124
+ /**
125
+ * Loads an ABI for a given contract.
126
+ * @param {string} contractName The name of the contract for which to load the ABI.
127
+ * @param {string | object} abi The ABI as a JSON string or object.
128
+ * @returns {boolean} True if the ABI was loaded successfully, false otherwise.
129
+ * @throws {Error} If the ABI format is invalid or loading fails.
130
+ */
131
+ loadAbi(contractName, abi) {
132
+ if (_Abieos.debug && _Abieos.loadedContracts.has(contractName)) {
133
+ console.info(`${_Abieos.logTag} Contract '${contractName}' is already loaded. Updating ABI...`);
134
+ }
135
+ const abiString = typeof abi === "object" ? JSON.stringify(abi) : abi;
136
+ if (typeof abiString !== "string") {
137
+ throw new Error(`${_Abieos.logTag} ABI must be a String or Object.`);
138
+ }
139
+ try {
140
+ const loaded = _Abieos.native.load_abi(contractName, abiString);
141
+ if (loaded) {
142
+ _Abieos.loadedContracts.set(contractName, Date.now());
143
+ if (_Abieos.debug) {
144
+ console.log(`${_Abieos.logTag} Loaded ABI for contract '${contractName}'.`);
145
+ }
146
+ }
147
+ return loaded;
148
+ } catch (e) {
149
+ throw new Error(`${_Abieos.logTag} Failed to load ABI for contract '${contractName}': ${e.message}`);
150
+ }
151
+ }
152
+ /**
153
+ * Loads an ABI for a given contract from its hexadecimal representation.
154
+ * @param {string} contractName The name of the contract for which to load the ABI.
155
+ * @param {string} abihex The ABI as a hexadecimal string.
156
+ * @returns {boolean} True if the ABI was loaded successfully, false otherwise.
157
+ * @throws {Error} If loading fails.
158
+ */
159
+ loadAbiHex(contractName, abihex) {
160
+ if (typeof abihex !== "string") {
161
+ throw new Error(`${_Abieos.logTag} ABI hex must be a String.`);
162
+ }
163
+ if (_Abieos.debug && _Abieos.loadedContracts.has(contractName)) {
164
+ console.info(`${_Abieos.logTag} Contract '${contractName}' is already loaded. Updating ABI...`);
165
+ }
166
+ try {
167
+ const loaded = _Abieos.native.load_abi_hex(contractName, abihex);
168
+ if (loaded) {
169
+ _Abieos.loadedContracts.set(contractName, Date.now());
170
+ if (_Abieos.debug) {
171
+ console.log(`${_Abieos.logTag} Loaded ABI hex for contract '${contractName}'.`);
172
+ }
173
+ }
174
+ return loaded;
175
+ } catch (e) {
176
+ throw new Error(`${_Abieos.logTag} Failed to load ABI hex for contract '${contractName}': ${e.message}`);
177
+ }
178
+ }
179
+ /**
180
+ * Retrieves the type name for a specific action within a contract's ABI.
181
+ * @param {string} contractName The name of the contract.
182
+ * @param {string} actionName The name of the action.
183
+ * @returns {string} The type name associated with the action.
184
+ * @throws {Error} If the contract or action is not found or another error occurs.
185
+ */
186
+ getTypeForAction(contractName, actionName) {
187
+ try {
188
+ return _Abieos.native.get_type_for_action(contractName, actionName);
189
+ } catch (e) {
190
+ throw new Error(`${_Abieos.logTag} Failed to get type for action '${actionName}' in contract '${contractName}': ${e.message}`);
191
+ }
192
+ }
193
+ /**
194
+ * Retrieves the type name for a specific table within a contract's ABI.
195
+ * @param {string} contractName The name of the contract.
196
+ * @param {string} table_name The name of the table.
197
+ * @returns {string} The type name associated with the table.
198
+ * @throws {Error} If the contract or table is not found or another error occurs.
199
+ */
200
+ getTypeForTable(contractName, table_name) {
201
+ try {
202
+ return _Abieos.native.get_type_for_table(contractName, table_name);
203
+ } catch (e) {
204
+ throw new Error(`${_Abieos.logTag} Failed to get type for table '${table_name}' in contract '${contractName}': ${e.message}`);
205
+ }
206
+ }
207
+ /**
208
+ * Deletes a contract's ABI from the abieos context.
209
+ * @param {string} contractName The name of the contract to delete.
210
+ * @returns {boolean} True if the contract was successfully deleted, false otherwise.
211
+ * @throws {Error} If deletion fails.
212
+ */
213
+ deleteContract(contractName) {
214
+ try {
215
+ const deleted = _Abieos.native.delete_contract(contractName);
216
+ if (deleted) {
217
+ _Abieos.loadedContracts.delete(contractName);
218
+ if (_Abieos.debug) {
219
+ console.log(`${_Abieos.logTag} Deleted contract '${contractName}' from abieos context.`);
220
+ }
221
+ }
222
+ return deleted;
223
+ } catch (e) {
224
+ throw new Error(`${_Abieos.logTag} Failed to delete contract '${contractName}': ${e.message}`);
225
+ }
226
+ }
227
+ };
228
+ export {
229
+ Abieos
230
+ };
package/dist/abieos.ts CHANGED
@@ -47,6 +47,7 @@ export class Abieos {
47
47
  */
48
48
  public cleanup(): void {
49
49
  /* node:coverage disable */
50
+ const errors: any[] = [];
50
51
  Abieos.loadedContracts.forEach((_, contractName) => {
51
52
  try {
52
53
  if (Abieos.debug) {
@@ -55,10 +56,14 @@ export class Abieos {
55
56
  Abieos.native.delete_contract(contractName);
56
57
  Abieos.loadedContracts.delete(contractName);
57
58
  } catch (e: any) {
59
+ errors.push({ contractName, error: e.message });
58
60
  console.error(`${Abieos.logTag} Failed to delete contract '${contractName}' during cleanup: ${e.message}`);
59
61
  }
60
62
  });
61
- /* node:coverage enable */
63
+ if (errors.length > 0) {
64
+ throw new Error(`${Abieos.logTag} Errors during cleanup: ${JSON.stringify(errors)}`);
65
+ }
66
+ /* node:coverage enable */
62
67
  }
63
68
 
64
69
  /**
package/package.json CHANGED
@@ -1,56 +1,56 @@
1
- {
2
- "name": "@eosrio/node-abieos",
3
- "version": "4.0.0-2039717",
4
- "publishConfig": {
5
- "access": "public",
6
- "tag": "abieos"
7
- },
8
- "description": "Node Bindings for abieos: Binary <> JSON conversion using ABIs.",
9
- "main": "./dist/abieos.js",
10
- "types": "./dist/abieos.d.ts",
11
- "type": "module",
12
- "exports": {
13
- ".": {
14
- "types": "./dist/abieos.d.ts",
15
- "import": "./dist/abieos.js",
16
- "require": "./dist/abieos.cjs"
17
- }
18
- },
19
- "scripts": {
20
- "install": "node -e 'process.exit(0)'",
21
- "build:linux": "cmake-js compile && node scripts/copy-module.mjs",
22
- "build": "tsup",
23
- "test": "node --test test/**/*.test.js",
24
- "test:coverage": "node --test --experimental-test-coverage test/**/*.test.js",
25
- "test:watch": "node --test --watch --experimental-test-coverage test/**/*.test.js",
26
- "tsc:watch": "tsc --watch",
27
- "clean": "cmake-js clean",
28
- "build:win": "cmake-js",
29
- "build:mac": "cmake-js",
30
- "update_version": "node scripts/update-version.mjs"
31
- },
32
- "repository": {
33
- "type": "git",
34
- "url": "git+https://github.com/eosrio/node-abieos.git"
35
- },
36
- "author": "EOS Rio",
37
- "license": "MIT",
38
- "bugs": {
39
- "url": "https://github.com/eosrio/node-abieos/issues"
40
- },
41
- "homepage": "https://github.com/eosrio/node-abieos#readme",
42
- "devDependencies": {
43
- "@microsoft/api-extractor": "7.52.8",
44
- "@wharfkit/antelope": "^1.0.13",
45
- "@types/node": "^22.15.21",
46
- "cmake-js": "7.3.1",
47
- "node-addon-api": "8.3.1",
48
- "tsup": "^8.5.0",
49
- "typescript": "5.8.3"
50
- },
51
- "binary": {
52
- "napi_versions": [
53
- 10
54
- ]
55
- }
1
+ {
2
+ "name": "@eosrio/node-abieos",
3
+ "version": "4.0.2-2039717",
4
+ "publishConfig": {
5
+ "access": "public",
6
+ "tag": "latest"
7
+ },
8
+ "description": "Node Bindings for abieos: Binary <> JSON conversion using ABIs.",
9
+ "main": "./dist/abieos.js",
10
+ "types": "./dist/abieos.d.ts",
11
+ "type": "module",
12
+ "exports": {
13
+ ".": {
14
+ "types": "./dist/abieos.d.ts",
15
+ "import": "./dist/abieos.js",
16
+ "require": "./dist/abieos.cjs"
17
+ }
18
+ },
19
+ "scripts": {
20
+ "install": "node -e 'process.exit(0)'",
21
+ "build:linux": "cmake-js compile && node scripts/copy-module.mjs",
22
+ "build": "tsup",
23
+ "test": "node --test test/**/*.test.js",
24
+ "test:coverage": "node --test --experimental-test-coverage test/**/*.test.js",
25
+ "test:watch": "node --test --watch --experimental-test-coverage test/**/*.test.js",
26
+ "tsc:watch": "tsc --watch",
27
+ "clean": "cmake-js clean",
28
+ "build:win": "cmake-js",
29
+ "build:mac": "cmake-js",
30
+ "update_version": "node scripts/update-version.mjs"
31
+ },
32
+ "repository": {
33
+ "type": "git",
34
+ "url": "git+https://github.com/eosrio/node-abieos.git"
35
+ },
36
+ "author": "EOS Rio",
37
+ "license": "MIT",
38
+ "bugs": {
39
+ "url": "https://github.com/eosrio/node-abieos/issues"
40
+ },
41
+ "homepage": "https://github.com/eosrio/node-abieos#readme",
42
+ "devDependencies": {
43
+ "@microsoft/api-extractor": "7.52.8",
44
+ "@wharfkit/antelope": "^1.0.13",
45
+ "@types/node": "^22.15.21",
46
+ "cmake-js": "7.3.1",
47
+ "node-addon-api": "8.3.1",
48
+ "tsup": "^8.5.0",
49
+ "typescript": "5.8.3"
50
+ },
51
+ "binary": {
52
+ "napi_versions": [
53
+ 10
54
+ ]
55
+ }
56
56
  }