Hot answers tagged

2 votes
Accepted

Is there a way to get an interface ID of a Solidity interface using ethersjs?

Currently there is not. You have to xor all function selectors of IMyContract. To make your life easier, you can use ethers.js interface and use its getSighash functions to not have to hash it and ...
user avatar
  • 391
1 vote

Is there a way to get an interface ID of a Solidity interface using ethersjs?

Here's how I solved it, Ethers v5 & Typescript with OpenZeppelin upgradeable contracts (will work with any type of contract). import { Contract, ContractInterface, ethers } from "ethers"...
user avatar

Only top scored, non community-wiki answers of a minimum length are eligible