2

Which version of the Ethers.js library, either v5 or v6, is recommended for me to learn and work with? I'm seeking advice on which version would be more beneficial for my current needs and future projects. Any insights or recommendations would be greatly appreciated.

1
  • 1
    Neither. I would recommend using Viem instead. Commented Nov 1, 2023 at 9:29

1 Answer 1

1

For learning ethers.js, it would be better to learn the latest version, v6 currently.

v6 allows you to also learn built-in ES2020 BigInt.

One of the biggest changes in v6 is that the BigNumber class has been replaced with the built-in ES2020 BigInt offered by modern JavaScript environments.

Because v5 didn't use the built-in BigInt, it ended up using a library, where the chances of bugs are higher, such as https://github.com/ethers-io/ethers.js/issues/3017

2
  • 1
    I fully concur, but for the purposes of readers who find this in the future, I'll add that in general I would recommend always using the latest version unless there's a specific reason not too Commented Nov 2, 2023 at 12:29
  • 1
    @TheRenaissance Agree. Readers should also know that older versions are unlikely to get any more updates or bug fixes, if any.
    – eth
    Commented Nov 2, 2023 at 21:08

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.