fisshy / react-scroll

React scroll component
https://github.com/fisshy/react-scroll/blob/master/README.md
MIT License
4.36k stars 437 forks source link

Is this not compatible with Vite? #550

Open TheLonerCoder opened 1 year ago

TheLonerCoder commented 1 year ago

I had no issues using this in my vanilla React projects. Tried to use it with vite and nothing works.. clicking a link doesn't scroll. I'm using the exact same code and the exact same version i'm using in vanilla React too. Anyone else got this to work with Vite?

rupinderDev commented 1 year ago

Hi, I am using it with vite without any problem.

ToneeEnguix commented 1 year ago

I'm getting the following breaking error in Vite: GET http://localhost:5173/node_modules/.vite/deps/react-scroll.js?t=1684163175571&v=7f14b061 net::ERR_ABORTED 504 (Outdated Optimize Dep)

Here's the repo: https://github.com/ToneeEnguix/el_sorrall To install run:

Error should appear. Help appreciated!

ToneeEnguix commented 1 year ago

ok I think my issue was very simple:

I just deleted package-lock.json and node_modules and ran npm i again.

Worked successfully.