next.js
ae3f9f51 - partial fallbacks: complete generic shells into more specific shells (#91231)

Commit
232 days ago
partial fallbacks: complete generic shells into more specific shells (#91231) In #91158, I wired up the plumbing to indicate whether a partial fallback shell is upgradeable. The previous heuristic was too coarse. This wires up the handling in `next start`. This PR teaches the runtime to complete a fallback shell only as far as prerendering allows. Instead of promoting a generic shell like `/[one]/[two]` directly to `/c/foo`, it promotes it to the most specific prerendered shell for that branch, `/c/[two]`, where `[one]` has `generateStaticParams`. That means later requests can reuse the more complete shell, while fully dynamic params continue to stream as dynamic content. With this change: - the first request still serves the generic fallback shell immediately - the background revalidate writes a more specific shell, not a fully concrete route - later requests for the same prerendered branch reuse that shell - upgrading stops once only fully dynamic params remain This keeps the runtime behavior aligned with the build-time `remainingPrerenderableParams` contract from the downstack PR.
Author
Parents
Loading