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

Incompatiable with [email protected] #22

@nijynot

Description

@nijynot

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?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions