Search params in Next.js page with route params will lead to a 404 client-side, only when hosted in Vercel #5778
Replies: 1 comment
-
It seems fixed using more recent versions. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Page to Investigate
https://www.ericburel.tech/blog/nextjs-stream-files
Steps to Reproduce
Hi,
I am using Next.js latest canary release 14.1.1-canary.44 and had an issue on a static page using generateStaticParams.
When searchParams are present in the page (due to tracker added by 3rd parties), the page would show the server-rendered version for a split second, and then display a 404 error after hydration.
Here is the server log corresponding to this issue.
Making the page dynamic had no effect so it feels like a problem with the route parameter, whether the page is static or not.
You can't currently reproduce the issue as I published a quickfix consisting in scraping away search params in a middleware, but it can be reproduced in @leerob blog (I reused his open source template), for instance: https://leerob.io/blog/2023?foo=bar
Beta Was this translation helpful? Give feedback.
All reactions