Replies: 2 comments 1 reply
-
Take a look at the docs: https://nextjs.org/docs/routing/shallow-routing By definition of the |
Beta Was this translation helpful? Give feedback.
0 replies
-
Per the docs, your shallow routing code would need to look like: router.push(`/jobs?${query}`, undefined, {
shallow: true,
}); |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Bug report
Describe the bug
When updating the query params of a route using the following code
The page scrolls to the top, and causes a "refresh/rerender"
A clear and concise description of what the bug is.
To Reproduce
Steps to reproduce the behavior, please provide code snippets or a repository:
Expected behavior
I would expect the page not to rerender, stay in the current scroll spot and update the query params without any extra things going on
Screenshots
If applicable, add screenshots to help explain your problem.
System information
Beta Was this translation helpful? Give feedback.
All reactions