Skip to content
This repository has been archived by the owner on Apr 25, 2024. It is now read-only.

Incompatiable with [email protected] #22

Open
nijynot opened this issue Jul 23, 2023 · 0 comments
Open

Incompatiable with [email protected] #22

nijynot opened this issue Jul 23, 2023 · 0 comments

Comments

@nijynot
Copy link

nijynot commented Jul 23, 2023

I'm using ethers with version 6.6.4.

When calling

const { domain, types, values } = AllowanceTransfer.getPermitData(
  permit,
  permitAddress,
  chainId
);
return signer.signTypedData(domain, types, values);

I get the error

Argument of type 'import("/node_modules/@ethersproject/abstract-signer/lib/index").TypedDataDomain' is not assignable to parameter of type 'import("/node_modules/ethers/lib.esm/hash/typed-data", { assert: { "resolution-mode": "import" } }).TypedDataDomain'.
  Types of property 'chainId' are incompatible.
    Type 'BigNumberish | undefined' is not assignable to type 'BigNumberish | null | undefined'.
      Type 'BigNumber' is not assignable to type 'BigNumberish | null | undefined'.ts(2345)

I think this is due to ethers on permit2-sdk being ethers 5, and I'm using ethers 6.
Are there any plans to be compatible with ethers 6, or that's up to the user to do?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant