You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I cannot use your incredible smooth scrolling library due to errors while importing in react js project. Please guide me to implement this in my project.
The text was updated successfully, but these errors were encountered:
It simply says that the window object is not defined and it seems like you are using Next.Js not just React.Js in your project. In Next.Js projects we call the window object a little differently.
Next.Js offeres server side rendering, which means that your site runs on the server before running on the client. There is no window object on the server (Node.Js). Therefore, try calling the window object from the useEffect Hook. Refer to this article for better explanation. https://articles.wesionary.team/window-object-in-nextjs-1e505349c6f5
I cannot use your incredible smooth scrolling library due to errors while importing in react js project. Please guide me to implement this in my project.
The text was updated successfully, but these errors were encountered: