router.replace option shallow
Unanswered
Serengeti posted this in #help-forum
SerengetiOP
the shallow option only doesn't allow the triggers: getStaticProps, getServerSideProps or getInitialProps.
Is there a way to only change the url but to NOT alter the page nor rerender?
Is there a way to only change the url but to NOT alter the page nor rerender?
3 Replies
Peterbald
Have you found the solution?
Boreal Chickadee
joining
can you try this
window.history.replaceState
on client side maybe - i think it should work for not just query params: https://nextjs.org/blog/next-14-1#windowhistorypushstate-and-windowhistoryreplacestate (or do you mean on server change the url?)