@dfinity/nns 11.1.4-next-2025-12-10.2 → 12.0.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.
Files changed (2) hide show
  1. package/README.md +4 -4
  2. package/package.json +3 -6
package/README.md CHANGED
@@ -32,7 +32,7 @@ npm i @icp-sdk/core @dfinity/utils
32
32
  Most features are provided through the use of classes. For example, querying the list of neurons controlled by the caller with the `governance` canister:
33
33
 
34
34
  ```ts
35
- import { GovernanceCanister } from "@dfinity/nns";
35
+ import { NnsGovernanceCanister } from "@dfinity/nns";
36
36
  import { createAgent } from "@dfinity/utils";
37
37
 
38
38
  const agent = await createAgent({
@@ -40,7 +40,7 @@ const agent = await createAgent({
40
40
  host: HOST,
41
41
  });
42
42
 
43
- const { listNeurons } = GovernanceCanister.create({
43
+ const { listNeurons } = NnsGovernanceCanister.create({
44
44
  agent,
45
45
  canisterId: MY_GOVERNANCE_CANISTER_ID,
46
46
  });
@@ -51,7 +51,7 @@ const myNeurons = await listNeurons({ certified: false });
51
51
  To execute this on a local environment, you will need to fetch the root key when initializing the agent. Additionally, you might need to adapt the port. The following snippet also demonstrates how you can inline a canister ID as well.
52
52
 
53
53
  ```typescript
54
- import { GovernanceCanister } from "@dfinity/nns";
54
+ import { NnsGovernanceCanister } from "@dfinity/nns";
55
55
  import { Principal } from "@icp-sdk/core/principal";
56
56
  import { createAgent } from "@dfinity/utils";
57
57
 
@@ -61,7 +61,7 @@ const agent = await createAgent({
61
61
  fetchRootKey: true,
62
62
  });
63
63
 
64
- const { listNeurons } = GovernanceCanister.create({
64
+ const { listNeurons } = NnsGovernanceCanister.create({
65
65
  agent,
66
66
  canisterId: Principal.fromText("rrkah-fqaaa-aaaaa-aaaaq-cai"),
67
67
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dfinity/nns",
3
- "version": "11.1.4-next-2025-12-10.2",
3
+ "version": "12.0.0",
4
4
  "description": "A library for interfacing with the Internet Computer's Network Nervous System.",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",
@@ -31,9 +31,6 @@
31
31
  "prepack": "npm run build",
32
32
  "test": "vitest"
33
33
  },
34
- "dependencies": {
35
- "@noble/hashes": "^1.8.0"
36
- },
37
34
  "repository": {
38
35
  "type": "git",
39
36
  "url": "git+https://github.com/dfinity/icp-js-canisters.git",
@@ -60,6 +57,6 @@
60
57
  "network-nervous-system"
61
58
  ],
62
59
  "peerDependencies": {
63
- "@icp-sdk/canisters": "*"
60
+ "@icp-sdk/canisters": "^3"
64
61
  }
65
- }
62
+ }