Closed oahmaro closed 2 years ago
Can you show me a reproduction? I'm afraid this isn't enough information to help.
This happens because Next calls event.preventDefault()
on any link click and handles both the navigation and the scroll internally, so smoothscroll-anchor-polyfill
can't intercept.
You can try the scroll-behavior-polyfill
package, it should work even with 3rd-party code that intercepts and calls .preventDefault()
like Next.js does. (but has some other trade-offs)
I followed every step in you documentation, and i just can't get it to work on a NextJS application