Hey JavaScript IC devs ,
Recently, we’ve observed sometimes a bit of confusion regarding which libraries should be used for interacting with which type of ledger. To address this and prevent future misunderstandings, we’ve introduced the following breaking changes in ic-js, which have just been published to NPM:
-
ICP ledger-related features have been relocated from
@dfinity/nns
to a new dedicated library called@dfinity/ledger-icp
-
ICRC ledger-related features have been moved as well. The library
@dfinity/ledger
has been deprecated, renamed, and replaced by@dfinity/ledger-icrc
-
@dfinity/ledger
is still available on NPM (for now), but it’s deprecated and will be retired at some point
In simpler terms:
- @dfinity/ledger-icp === ICP ledger
- @dfinity/ledger-icrc === Any Snses, ckBTC, or other ICRC tokens
Additionally, we’ve decided to adopt semantic versioning. Since everything is functioning smoothly now, all libraries have been bumped to at least v1.0.0
.
Furthermore, we’ve enhanced our CI pipeline. This means that upon new releases, only the libraries that have received changes will be published, in contrast to our previous practice of publishing everything each time.
To provide a clear overview, we’ve introduced a release table in each release. This allows you to easily identify what has been updated or remains unchanged. You can see an example of today’s last release here https://github.com/dfinity/ic-js/releases/tag/2023.10.02-1515Z
Library | Version | Status |
---|---|---|
@dfinity/ckbtc |
v1.0.1 | Patched |
@dfinity/cmc |
v1.0.0 | Unchanged |
@dfinity/ic-management |
v1.0.0 | Unchanged |
@dfinity/ledger |
v1.0.0 | Deprecated |
@dfinity/ledger-icp |
v1.0.0 | New |
@dfinity/ledger-icrc |
v1.0.0 | New |
@dfinity/nns |
v2.0.0 | Breaking Changes |
@dfinity/nns-proto |
v1.0.0 | Unchanged |
@dfinity/sns |
v1.0.0 | Patched |
@dfinity/utils |
v1.0.0 | Unchanged |
Hope that’s cool?
Please don’t hesitate to reach out with any questions or observations!