next.js
8aa475b4 - Redesign the unrendered-segment instant validation overlay (#93879)

Commit
25 days ago
Redesign the unrendered-segment instant validation overlay (#93879) ### What? A focused dev-overlay redesign and CLI/build message refresh for the "expected segment was not rendered" instant validation warning (PR #93770). Now integrated with the Errors/Insights tab split from #94073. ### Why? The wrapper carries no useful source location to point at — the code-frame chrome and Call Stack the overlay rendered before were misleading. Users mostly need to know which segment didn't render and where to set `instant = false` to silence the warning. ### Demo - [Demo 1](https://error-messages-overhaul-ibsl.labs.vercel.dev/scenario/81-instant-wrapper-unrendered-segment) - [Demo 2](https://error-messages-overhaul-ibsl.labs.vercel.dev/scenario/82-nested-layouts-unrendered-segment) - [Demo 3](https://error-messages-overhaul-ibsl.labs.vercel.dev/scenario/83-conditional-render-unrendered-segment) - [Demo 4](https://error-messages-overhaul-ibsl.labs.vercel.dev/scenario/84-parallel-slot-unrendered-segment) ### How - Restructured framework message in `dynamic-rendering.ts`: leads with `Route "<path>":` prefix like every other validation factory, drops the verbose paragraphs in favour of a one-sentence explanation + `Ways to fix this:` list, and uses `instant` not `unstable_instant` in the fix bullet. - New `unrendered-segment` `GuidanceKind` and a dedicated case in `errors.tsx` that drops the code-frame and Call Stack. - New `UnrenderedSegmentInfo` component renders the route + each unrendered file with the same chrome as `CodeFrame`, plus open-in-editor. - Two fix cards: `Render the missing segment` (render, gray) and `Allow no validation` (silence, red). - **Errors/Insights tab integration**: `isInstantNavigationError` now returns `true` for unrendered-segment errors, so they appear under the **Insights** tab with the amber pill (not the red Issues tab). They clear on navigation like other instant errors. Added `renderTabBar` to the unrendered-segment overlay layout. --------- Co-authored-by: Cursor <cursoragent@cursor.com> Co-authored-by: Yavor Punchev <yavor.punchev@gmail.com>
Author
Parents
Loading