Repository navigation
Replies: 1 comment 2 replies
|
You reading it right, and the demo is showing the correct behavior. That third bullet describes a different step than the one you're thinking of. There are two separate things:
What you never get is something like That's what "params are resolved in route order" means. If category is missing, any deeper param can only be a fallback too, so a visit to
In short, the bullet limits which shell a first visit can get. It doesn't limit what the upgrade produces. I think that's what's happening here π€ β I'll revisit the bullet point at some point, as per feedback... it needs some adjustment. |
Uh oh!
There was an error while loading. Please reload this page.
Summary
Firstly, At runtime says:
"The first visit to /shoes/basketball-shoes. Neither param was prerendered. Next.js serves the generic App Shell for /[category]/[product]. Both the category and the product stream in.
After the first visit, Next.js renders these routes in the background with the now-known params. The next visitor to the same URLs gets the upgraded result."
It is natural to think that
upgraded resultfor/shoes/basketball-shoesis a fully static page. And it is verified using the demo.However, What the upgrade produces says in its 3rd bullet point:
"Params are resolved in route order. A param value not returned by generateStaticParams stays unresolved and prevents any deeper params from upgrading."
If I reason correctly,
/shoes/basketball-shoeswould not be upgraded to a fully static page becauseshoesis not a listed category, which contradicts the observed behavior.Can someone explain to me? Thanks
Additional information
No response
Example
No response
All reactions