use-smooth-scroll
use-smooth-scroll copied to clipboard
window is not defined on SSR
'useSmoothScroll' is trying to access the window object on server-side.
just importing the package in a component would result to this error, I tried to require and run it inside useEffect but obviously, it won’t work as it's a hook itself.
Please always try to share a repro case in a runnable form - either by providing a git repository to clone or a codesandbox. OSS maintainers usually can't afford the time to set up the repro, even if exact steps are given.