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
Currently getInitialProps runs once on the server and once on the client. Is there a way to disable it from running on the client or preserving the props it got from the server render on certain pages?
The text was updated successfully, but these errors were encountered:
To make it clear, getInitialProps runs on server if it's server rendering, and does on client if page transition occurs by using Link component or props.url.push().
If you don't want to provide props on client for example, you can write like the following.
For some reason getInitialProps is running on the client as soon as it mounts. Maybe it's because I'm using next's programmatic API. I'll be looking into it to see if it's a problem on my end.
Currently getInitialProps runs once on the server and once on the client. Is there a way to disable it from running on the client or preserving the props it got from the server render on certain pages?
The text was updated successfully, but these errors were encountered: