@icp-sdk/core 1.0.0-beta.0
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 +87 -0
- package/lib/cjs/agent/index.d.ts +1 -0
- package/lib/cjs/agent/index.js +18 -0
- package/lib/cjs/agent/index.js.map +1 -0
- package/lib/cjs/assets/index.d.ts +1 -0
- package/lib/cjs/assets/index.js +18 -0
- package/lib/cjs/assets/index.js.map +1 -0
- package/lib/cjs/auth-client/index.d.ts +1 -0
- package/lib/cjs/auth-client/index.js +18 -0
- package/lib/cjs/auth-client/index.js.map +1 -0
- package/lib/cjs/candid/index.d.ts +1 -0
- package/lib/cjs/candid/index.js +18 -0
- package/lib/cjs/candid/index.js.map +1 -0
- package/lib/cjs/identity/index.d.ts +1 -0
- package/lib/cjs/identity/index.js +18 -0
- package/lib/cjs/identity/index.js.map +1 -0
- package/lib/cjs/identity-secp256k1/index.d.ts +1 -0
- package/lib/cjs/identity-secp256k1/index.js +18 -0
- package/lib/cjs/identity-secp256k1/index.js.map +1 -0
- package/lib/cjs/index.d.ts +0 -0
- package/lib/cjs/index.js +3 -0
- package/lib/cjs/index.js.map +1 -0
- package/lib/cjs/principal/index.d.ts +1 -0
- package/lib/cjs/principal/index.js +18 -0
- package/lib/cjs/principal/index.js.map +1 -0
- package/lib/esm/agent/index.d.ts +1 -0
- package/lib/esm/agent/index.js +2 -0
- package/lib/esm/agent/index.js.map +1 -0
- package/lib/esm/assets/index.d.ts +1 -0
- package/lib/esm/assets/index.js +2 -0
- package/lib/esm/assets/index.js.map +1 -0
- package/lib/esm/auth-client/index.d.ts +1 -0
- package/lib/esm/auth-client/index.js +2 -0
- package/lib/esm/auth-client/index.js.map +1 -0
- package/lib/esm/candid/index.d.ts +1 -0
- package/lib/esm/candid/index.js +2 -0
- package/lib/esm/candid/index.js.map +1 -0
- package/lib/esm/identity/index.d.ts +1 -0
- package/lib/esm/identity/index.js +2 -0
- package/lib/esm/identity/index.js.map +1 -0
- package/lib/esm/identity-secp256k1/index.d.ts +1 -0
- package/lib/esm/identity-secp256k1/index.js +2 -0
- package/lib/esm/identity-secp256k1/index.js.map +1 -0
- package/lib/esm/index.d.ts +0 -0
- package/lib/esm/index.js +3 -0
- package/lib/esm/index.js.map +1 -0
- package/lib/esm/principal/index.d.ts +1 -0
- package/lib/esm/principal/index.js +2 -0
- package/lib/esm/principal/index.js.map +1 -0
- package/package.json +110 -0
package/README.md
ADDED
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
# @icp-sdk/core
|
|
2
|
+
|
|
3
|
+
The `@icp-sdk/core` package is a JavaScript and TypeScript library designed to interact with the Internet Computer. It acts as a meta-package that re-exports functionality from several other `@dfinity` packages, providing a convenient way to access multiple tools and utilities in one place.
|
|
4
|
+
|
|
5
|
+
**Note:** This package requires the `node16` (or later) module resolution strategy to function correctly.
|
|
6
|
+
|
|
7
|
+
## Installation
|
|
8
|
+
|
|
9
|
+
You can install the `@icp-sdk/core` package using your preferred package manager:
|
|
10
|
+
|
|
11
|
+
### npm
|
|
12
|
+
```bash
|
|
13
|
+
npm install @icp-sdk/core
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
### yarn
|
|
17
|
+
```bash
|
|
18
|
+
yarn add @icp-sdk/core
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
### pnpm
|
|
22
|
+
```bash
|
|
23
|
+
pnpm add @icp-sdk/core
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
## Package Structure
|
|
27
|
+
|
|
28
|
+
The `@icp-sdk/core` package re-exports modules from the following `@dfinity` packages:
|
|
29
|
+
|
|
30
|
+
- [`@dfinity/agent`](../agent/README.md): Provides tools to interact with the Internet Computer, including creating actors and making calls.
|
|
31
|
+
- [`@dfinity/assets`](../assets/README.md): Utilities for managing assets on the Internet Computer.
|
|
32
|
+
- [`@dfinity/auth-client`](../auth-client/README.md): Handles authentication flows, including integration with Internet Identity.
|
|
33
|
+
- [`@dfinity/candid`](../candid/README.md): Tools for working with Candid, the Internet Computer's interface definition language.
|
|
34
|
+
- [`@dfinity/identity`](../identity/README.md): Identity management for signing and authentication.
|
|
35
|
+
- [`@dfinity/identity-secp256k1`](../identity-secp256k1/README.md): Identity management using secp256k1 cryptography.
|
|
36
|
+
- [`@dfinity/principal`](../principal/README.md): Utilities for working with principals on the Internet Computer.
|
|
37
|
+
|
|
38
|
+
## Import Paths
|
|
39
|
+
|
|
40
|
+
The package provides the following import paths for accessing the re-exported modules:
|
|
41
|
+
|
|
42
|
+
- `@icp-sdk/core/agent`
|
|
43
|
+
- `@icp-sdk/core/assets`
|
|
44
|
+
- `@icp-sdk/core/auth-client`
|
|
45
|
+
- `@icp-sdk/core/candid`
|
|
46
|
+
- `@icp-sdk/core/identity`
|
|
47
|
+
- `@icp-sdk/core/identity-secp256k1`
|
|
48
|
+
- `@icp-sdk/core/principal`
|
|
49
|
+
|
|
50
|
+
## Usage Example
|
|
51
|
+
|
|
52
|
+
Here is an example of how to use the `@icp-sdk/core` package:
|
|
53
|
+
|
|
54
|
+
```typescript
|
|
55
|
+
// Importing the HttpAgent from the agent module
|
|
56
|
+
import { HttpAgent } from '@icp-sdk/core/agent';
|
|
57
|
+
|
|
58
|
+
// Importing the Principal utility
|
|
59
|
+
import { Principal } from '@icp-sdk/core/principal';
|
|
60
|
+
|
|
61
|
+
// Create an HttpAgent instance
|
|
62
|
+
const agent = new HttpAgent({ host: 'https://ic0.app' });
|
|
63
|
+
|
|
64
|
+
// Create a Principal from a string
|
|
65
|
+
const principal = Principal.fromText('aaaaa-aa');
|
|
66
|
+
|
|
67
|
+
// Log the Principal
|
|
68
|
+
console.log(principal.toText());
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
For detailed usage and API documentation, refer to the respective documentation of the re-exported packages:
|
|
72
|
+
|
|
73
|
+
- [@dfinity/agent Documentation](../agent/README.md)
|
|
74
|
+
- [@dfinity/assets Documentation](../assets/README.md)
|
|
75
|
+
- [@dfinity/auth-client Documentation](../auth-client/README.md)
|
|
76
|
+
- [@dfinity/candid Documentation](../candid/README.md)
|
|
77
|
+
- [@dfinity/identity Documentation](../identity/README.md)
|
|
78
|
+
- [@dfinity/identity-secp256k1 Documentation](../identity-secp256k1/README.md)
|
|
79
|
+
- [@dfinity/principal Documentation](../principal/README.md)
|
|
80
|
+
|
|
81
|
+
## Contributing
|
|
82
|
+
|
|
83
|
+
Contributions are welcome! Please refer to the [repository](https://github.com/dfinity/agent-js) for guidelines on contributing to this project.
|
|
84
|
+
|
|
85
|
+
## License
|
|
86
|
+
|
|
87
|
+
This project is licensed under the Apache-2.0 License. See the [LICENSE](https://github.com/dfinity/agent-js/blob/main/LICENSE) file for details.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@dfinity/agent';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("@dfinity/agent"), exports);
|
|
18
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/agent/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,iDAA+B","sourcesContent":["export * from '@dfinity/agent';\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@dfinity/assets';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("@dfinity/assets"), exports);
|
|
18
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/assets/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,kDAAgC","sourcesContent":["export * from '@dfinity/assets';\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@dfinity/auth-client';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("@dfinity/auth-client"), exports);
|
|
18
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/auth-client/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,uDAAqC","sourcesContent":["export * from '@dfinity/auth-client';\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@dfinity/candid';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("@dfinity/candid"), exports);
|
|
18
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/candid/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,kDAAgC","sourcesContent":["export * from '@dfinity/candid';\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@dfinity/identity';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("@dfinity/identity"), exports);
|
|
18
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/identity/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,oDAAkC","sourcesContent":["export * from '@dfinity/identity';\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@dfinity/identity-secp256k1';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("@dfinity/identity-secp256k1"), exports);
|
|
18
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/identity-secp256k1/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,8DAA4C","sourcesContent":["export * from '@dfinity/identity-secp256k1';\n"]}
|
|
File without changes
|
package/lib/cjs/index.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";AAAA,MAAM,IAAI,KAAK,CAAC,yJAAyJ,CAAC,CAAC","sourcesContent":["throw new Error('There are no exports in the root module of this package. Import from submodules instead. Use intellisense or the docs to find the available submodules.');\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@dfinity/principal';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("@dfinity/principal"), exports);
|
|
18
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/principal/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,qDAAmC","sourcesContent":["export * from '@dfinity/principal';\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@dfinity/agent';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/agent/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC","sourcesContent":["export * from '@dfinity/agent';\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@dfinity/assets';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/assets/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC","sourcesContent":["export * from '@dfinity/assets';\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@dfinity/auth-client';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/auth-client/index.ts"],"names":[],"mappings":"AAAA,cAAc,sBAAsB,CAAC","sourcesContent":["export * from '@dfinity/auth-client';\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@dfinity/candid';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/candid/index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAiB,CAAC","sourcesContent":["export * from '@dfinity/candid';\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@dfinity/identity';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/identity/index.ts"],"names":[],"mappings":"AAAA,cAAc,mBAAmB,CAAC","sourcesContent":["export * from '@dfinity/identity';\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@dfinity/identity-secp256k1';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/identity-secp256k1/index.ts"],"names":[],"mappings":"AAAA,cAAc,6BAA6B,CAAC","sourcesContent":["export * from '@dfinity/identity-secp256k1';\n"]}
|
|
File without changes
|
package/lib/esm/index.js
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/index.ts"],"names":[],"mappings":";AAAA,MAAM,IAAI,KAAK,CAAC,yJAAyJ,CAAC,CAAC","sourcesContent":["throw new Error('There are no exports in the root module of this package. Import from submodules instead. Use intellisense or the docs to find the available submodules.');\n"]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@dfinity/principal';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/principal/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC","sourcesContent":["export * from '@dfinity/principal';\n"]}
|
package/package.json
ADDED
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@icp-sdk/core",
|
|
3
|
+
"version": "1.0.0-beta.0",
|
|
4
|
+
"author": "DFINITY Stiftung <sdk@dfinity.org>",
|
|
5
|
+
"license": "Apache-2.0",
|
|
6
|
+
"description": "JavaScript and TypeScript library to interact with the Internet Computer",
|
|
7
|
+
"homepage": "https://internetcomputer.org",
|
|
8
|
+
"repository": {
|
|
9
|
+
"type": "git",
|
|
10
|
+
"url": "https://github.com/dfinity/agent-js.git",
|
|
11
|
+
"directory": "packages/core"
|
|
12
|
+
},
|
|
13
|
+
"bugs": {
|
|
14
|
+
"url": "https://github.com/dfinity/agent-js/issues"
|
|
15
|
+
},
|
|
16
|
+
"keywords": [
|
|
17
|
+
"internet computer",
|
|
18
|
+
"internet-computer",
|
|
19
|
+
"ic",
|
|
20
|
+
"dfinity",
|
|
21
|
+
"agent",
|
|
22
|
+
"actor",
|
|
23
|
+
"dfx",
|
|
24
|
+
"canister",
|
|
25
|
+
"candid",
|
|
26
|
+
"motoko",
|
|
27
|
+
"javascript",
|
|
28
|
+
"typescript",
|
|
29
|
+
"blockchain",
|
|
30
|
+
"crypto",
|
|
31
|
+
"distributed",
|
|
32
|
+
"api",
|
|
33
|
+
"sdk"
|
|
34
|
+
],
|
|
35
|
+
"scripts": {
|
|
36
|
+
"build": "tsc -b && tsc -p tsconfig.cjs.json",
|
|
37
|
+
"build:watch": "tsc -b --watch",
|
|
38
|
+
"bundle": "esbuild --bundle src/index.ts --outfile=dist/index.js --platform=browser",
|
|
39
|
+
"make:docs/reference": "typedoc src/index.ts --out ../../docs/icp --excludeInternal",
|
|
40
|
+
"attw": "attw --pack . --profile node16"
|
|
41
|
+
},
|
|
42
|
+
"peerDependencies": {
|
|
43
|
+
"@dfinity/agent": "workspace:*",
|
|
44
|
+
"@dfinity/assets": "workspace:*",
|
|
45
|
+
"@dfinity/auth-client": "workspace:*",
|
|
46
|
+
"@dfinity/candid": "workspace:*",
|
|
47
|
+
"@dfinity/identity": "workspace:*",
|
|
48
|
+
"@dfinity/identity-secp256k1": "workspace:*",
|
|
49
|
+
"@dfinity/principal": "workspace:*",
|
|
50
|
+
"@dfinity/use-auth-client": "workspace:*"
|
|
51
|
+
},
|
|
52
|
+
"exports": {
|
|
53
|
+
".": {
|
|
54
|
+
"types": "./lib/esm/index.d.ts",
|
|
55
|
+
"node": "./lib/cjs/index.js",
|
|
56
|
+
"require": "./lib/cjs/index.js",
|
|
57
|
+
"import": "./lib/esm/index.js",
|
|
58
|
+
"default": "./lib/esm/index.js"
|
|
59
|
+
},
|
|
60
|
+
"./agent": {
|
|
61
|
+
"types": "./lib/esm/agent/index.d.ts",
|
|
62
|
+
"node": "./lib/cjs/agent/index.js",
|
|
63
|
+
"require": "./lib/cjs/agent/index.js",
|
|
64
|
+
"import": "./lib/esm/agent/index.js",
|
|
65
|
+
"default": "./lib/esm/agent/index.js"
|
|
66
|
+
},
|
|
67
|
+
"./assets": {
|
|
68
|
+
"types": "./lib/esm/assets/index.d.ts",
|
|
69
|
+
"node": "./lib/cjs/assets/index.js",
|
|
70
|
+
"require": "./lib/cjs/assets/index.js",
|
|
71
|
+
"import": "./lib/esm/assets/index.js",
|
|
72
|
+
"default": "./lib/esm/assets/index.js"
|
|
73
|
+
},
|
|
74
|
+
"./auth-client": {
|
|
75
|
+
"types": "./lib/esm/auth-client/index.d.ts",
|
|
76
|
+
"node": "./lib/cjs/auth-client/index.js",
|
|
77
|
+
"require": "./lib/cjs/auth-client/index.js",
|
|
78
|
+
"import": "./lib/esm/auth-client/index.js",
|
|
79
|
+
"default": "./lib/esm/auth-client/index.js"
|
|
80
|
+
},
|
|
81
|
+
"./candid": {
|
|
82
|
+
"types": "./lib/esm/candid/index.d.ts",
|
|
83
|
+
"node": "./lib/cjs/candid/index.js",
|
|
84
|
+
"require": "./lib/cjs/candid/index.js",
|
|
85
|
+
"import": "./lib/esm/candid/index.js",
|
|
86
|
+
"default": "./lib/esm/candid/index.js"
|
|
87
|
+
},
|
|
88
|
+
"./identity": {
|
|
89
|
+
"types": "./lib/esm/identity/index.d.ts",
|
|
90
|
+
"node": "./lib/cjs/identity/index.js",
|
|
91
|
+
"require": "./lib/cjs/identity/index.js",
|
|
92
|
+
"import": "./lib/esm/identity/index.js",
|
|
93
|
+
"default": "./lib/esm/identity/index.js"
|
|
94
|
+
},
|
|
95
|
+
"./identity-secp256k1": {
|
|
96
|
+
"types": "./lib/esm/identity-secp256k1/index.d.ts",
|
|
97
|
+
"node": "./lib/cjs/identity-secp256k1/index.js",
|
|
98
|
+
"require": "./lib/cjs/identity-secp256k1/index.js",
|
|
99
|
+
"import": "./lib/esm/identity-secp256k1/index.js",
|
|
100
|
+
"default": "./lib/esm/identity-secp256k1/index.js"
|
|
101
|
+
},
|
|
102
|
+
"./principal": {
|
|
103
|
+
"types": "./lib/esm/principal/index.d.ts",
|
|
104
|
+
"node": "./lib/cjs/principal/index.js",
|
|
105
|
+
"require": "./lib/cjs/principal/index.js",
|
|
106
|
+
"import": "./lib/esm/principal/index.js",
|
|
107
|
+
"default": "./lib/esm/principal/index.js"
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
}
|