Monkeypatch for ENSIP-19 (Multichain Primary) and ENSIP-23 (UniversalResolver) support in ethers.js.
npm i @ensdomains/ethers-patch-v5 ✓
npm i @ensdomains/ethers-patch-v6 ✓
import { ethers } from "ethers";
import "@ensdomains/ethers-patch-v5"; // or "-v6" resolveName()supports optionalcoinType- use
coinType = "old"for unpatched implementation
- use
lookupAddress()supports optionalcoinType- use
coinType = "old"for unpatched implementation
- use
- ENSIP-10 implementation uses
UniversalResolver.requireResolver() {Ens}Resolver.supportsWildcard()is noop- v5
- use
getResolverOld()for unpatched implementation - updated normalization to @adraffy/ens-normalize
namehash()is patcheddnsEncode()is patched and uses 255-byte limitensNormalize()is exposed
- use
- v6
- use
fromNameOld()for unpatched implementation
- use
- ☑︎ Downgrade versions to lowest supported
- ☑︎ Explore normalization options for v5
- ☑︎ Separate libraries
- ☑︎ Add tests for checking patched return types
- ☑︎ Add tests for failures
bun i
bun test
bun run apply— propagatepackage.jsonchanges to workspacesbun run build— builddist/
npm publish -ws