Skip to content

Conversation

@Nesopie
Copy link
Contributor

@Nesopie Nesopie commented Sep 4, 2024

  • Add support for CJS and ESM
  • Moved from typeforce (does not have esm support) to Valibot
  • Replaced Buffer usage to Uint8Array
  • There are 44 less test cases now as all logic with regards to writeUint64 and related functions has been moved to uint8array-tools.
  • All amount / value fields now use bigints

Copy link
Member

@junderw junderw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Legend!

Let's publish rc1 versions of all the major dependencies, then fix them in package.json here, then push rc1 version for bitcoinjs-lib.

@junderw junderw merged commit d6fe656 into bitcoinjs:master Sep 8, 2024
@landabaso
Copy link
Member

Great work on this HUGE refactor, @Nesopie! 👏

I noticed two related changes:

  • 9c3e8cc – drops the named exports ripemd160, sha1, and sha256.
  • 847090c – removes the unit tests that covered those helpers.

Because the PR is so large, I'm not sure whether that removal was intentional or an unintended side-effect.

A few of my own projects (and several others I found doing a quick internet search) use crypto.sha256, for example. Restoring the helpers would simplify the upgrade path to v7.

If the removal was accidental, I'm happy to open a follow-up PR that re-exports wrappers around Noble's hashes and brings the tests back.
If it was deliberate, it would be helpful to note it in the CHANGELOG.

Thanks again for all the work that went into this release!

@junderw
Copy link
Member

junderw commented Jun 28, 2025

Still haven't released 7.0.0 yet, so we can definitely get that in before 7.0.0 release if you want.

@landabaso
Copy link
Member

Still haven't released 7.0.0 yet, so we can definitely get that in before 7.0.0 release if you want.

Great. I'll take it from here.

BTW, npm install bitcoinjs-lib now pulls in 6.1.7.
7.0.0-rc0 used to be the default, but I think that changed once the v6 patch from #2184 was later published to npm.

Once the helpers and tests are restored, if we still want the RC to be the latest, we can push a fresh RC and retag latest back to v7.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants