Highlights ethers.js: August 2023
RicMoo — August 10, 2023

The current version of ethers as of this article is 6.7.0.

Roadtripping around -- Quidi Vidi, St. Johns

Ahoy!

It's been a while since I've posted a Highlights article, so there is a bit to catch up on.

The biggest news is that v6 has been out for 6 months and gaining more traction each day. Many of the features of v6 have been around using more standard tooling, modern JavaScript features and a simplified package structure.

At a glance...

Over the last 6 months there have been plenty of updates but in the last couple weeks a few come to mind:

  • Polygon now supports the official Polygon Gas Station, so transactions are fast, never stuck and not ignored by the network
  • Custom priority fees, which significantly reduce the cost of Optimism transactions
  • Enabled whitelist-only backends in the default provider to restrict to desired services

Extension Packages

An important goal of v6 is that of delegation. By breaking extension packages out of the core package, external contributions are much easier to review and accept and allows for domain experts to manage official extensions.

LedgerSigner

The LedgerSigner class provides seamless integration with Ledger Hardware Wallets as a standard Ethers signer. Several of the write-contributors of the extension repo are actual members of the Ledger team, so the library can be more intimately updated in-step with the Ledger libraries.

GanacheProvider

The GanacheProvider class provides quick and easy access to an in-memory node for testing purposes, backed by Ganache with extra configuration to improve its performance as well as some extras that the Ganache API provides to make testing certain situations simpler (like snapshots).

MulticoinProviderPlugin

Ethers has from the beginning supported many of the powerful features of ENS, but one feature has always been a bit nerfed; multi-coin support. All EVM-compatible chains available using ENSIP-11 are supported, since the required code is fairly minimal, however to support the full breadth of coins, such as Bitcoin, ZCash, Filecoin, et al. additional hashing and encoding libraries are required which would quickly bloat Ethers (which aims to remain slim). So, the MulticoinProviderPlugin is provided to extend a Provider, adding all coins supported by the ENS team, who are also write-contributor members of the extension repo.

Upcoming Extensions

  • Account Abstraction
  • Common Contracts (including lots of built-in futzing for not-entirely-standard ERC-20 contracts)
  • Typed Contracts (an experimental package, that will be ported into core once everyone is happy with it ;))

Conclusion

A huge thanks for dropping by! If you have any comments or suggestions, ping me on Formerly-known-as-Twitter or Discord. <3

• • •

"Another visitor. Stay a while... Stay forever!"