pancakeswap / pancake-frontend

:pancakes: Pancake main features (farms, pools, IFO, lottery, profiles)
https://pancakeswap.finance
GNU General Public License v3.0
2.69k stars 3.55k forks source link

[BUG] Failed to compile #2006

Closed alcyada closed 2 years ago

alcyada commented 3 years ago

Is there an existing issue for this?

Product

Other

Current Behavior

TypeScript error in /home/kingui/pancake-frontenit/src/hooks/useApproveCallback(86.7)

Argument of type "import("/home/kingui/pancake-frontend/node nodules/gethersproject/contracts/lib/index").Contract is not assignable to parameter of type import("/home/kingul/pancake-frontend /node_modules/ethers/node_sodules/gethersproject/contracts/lib/index").Contract.

Types of property runningevents are incompatible.

Type [eventTag: string]: RunningEvent: 1 is not assignable to type [eventTag: string]:Running Event: }'. Two different types with this name exist, but they are unrelated.

Index signatures are incompatible.

Type 'Running Event is not assignable to type RunningEvent. Two different types with this name

exist, but they are unrelated. Types have separate declarations of a private property listeners". 152345

851

87 1

// estint-disable-next-tine consistent-return

return callWithGasPricel tokenContract.

"approve

[spender, useExact amount ToApprove.raw.toString(): Max256),

Expected Behavior

It's supposed to compile

Steps To Reproduce

npm install npm run start

Environment

- Device: kvm 
- OS: ubuntu 20
- Browser: Firfox
- Wallet:

Anything else?

No response

tom-bowern commented 3 years ago

did you get this running?

alcyada commented 3 years ago

did you get this running?

No I didn't

alcyada commented 3 years ago

@tom-bowern can you help us with this?

tom-bowern commented 3 years ago

Unfortunately not I have the same issue :(

@tom-bowern can you help us with this?

alcyada commented 3 years ago

Unfortunately not I have the same issue :(

@tom-bowern can you help us with this? Sad to hear.

alcyada commented 3 years ago

@tom-bowern do you know of any alternative

Nikhil1419 commented 3 years ago

Use Yarn instead!! @alcyada

matbrgz commented 2 years ago

try to clone project again, DO NOT USE NPM. Use Yarn instead.

0xjojoex commented 2 years ago

Try following steps:

  1. remove node_modules and package-lock.json (if you have)
  2. yarn install

Free feel to re-open this issue if you still encounter this.

farhanali2325 commented 2 years ago

I have done the above steps, but still, I am getting the same error. Can somebody guide me?