When Next 12 is displaying 404? #44950
Unanswered
davletovalmir
asked this question in
Help
Replies: 1 suggested answer
-
One update: we noticed that Next router failed to interpolate the dynamic route variables and passed "[slug]" to the component instead of slug value or even undefined. |
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
{{editor}}'s edit
{{editor}}'s edit
-
We recently upgraded React to v18, and whenever we deploy it to production, we face 404 on the pages with SSG enabled and
{ fallback: true }
ingetStaticPaths
. It works fine on staging, which is as close to production as possible (except traffic and analytics). We assume that it might have some issues with the highly loaded pages, when Next is trying to build the SSG page that was not built yet, but receiving too many requests and serving fallback pages instead, and for some reason results in "404 | This page could not be found." page.Some facts:
pages/404.js
, and it looks different (UI). The 404 we receive is standard Next.js 404 page (see the screenshot below)I wanted to learn more on the cases when Next.js could act like it acts in our production with React 18. Understanding it will be key to understanding the nature of the bug and might help us dig into the right direction.
Thank you,
Almir from LeetCode
Beta Was this translation helpful? Give feedback.