Bug
When a page provides an unknown slot name (typo), the validation computes Levenshtein-based suggestions (e.g., headr → "Did you mean header?") but these warnings are never surfaced to the developer.
Root cause
render-page.tsx:117-121 runs validateSlots() and checks validation.errors (missing required slots), but ignores validation.warnings entirely:
const validation = validateSlots({ providedSlots, extractedSlots });
if (validation.errors.length > 0) {
throw new Error(validation.errors.map((e) => e.message).join("; "));
}
// validation.warnings is never read
Expected
In dev mode, warnings should be logged to console. The Levenshtein suggestion is computed but never shown — wasted work.
Reproduction
Create a route with slot name headr (typo for header). Get a generic 500 with "Required slot 'header' is missing" — no mention of the typo or suggestion.
Related
Test issue #156, item 18.
🤖 Generated with Claude Code
Bug
When a page provides an unknown slot name (typo), the validation computes Levenshtein-based suggestions (e.g.,
headr→ "Did you mean header?") but these warnings are never surfaced to the developer.Root cause
render-page.tsx:117-121runsvalidateSlots()and checksvalidation.errors(missing required slots), but ignoresvalidation.warningsentirely:Expected
In dev mode, warnings should be logged to console. The Levenshtein suggestion is computed but never shown — wasted work.
Reproduction
Create a route with slot name
headr(typo forheader). Get a generic 500 with "Required slot 'header' is missing" — no mention of the typo or suggestion.Related
Test issue #156, item 18.
🤖 Generated with Claude Code