Duolith docs

Errors E0500 to E0599

E0500 A match misses a case

Message this <match> has no case for value

Words in italics are filled in when the compiler reports it, such as the element's name or the list of known ones.

Why

A <match value={...}> without <case else> must have a <case is="..."> for every member of its value's union, so a state nobody wrote markup for fails the build instead of showing nothing (decision 0098). The script view writes the match as a switch whose last branch can only be reached by a value no case names, and TypeScript names that value.

How to fix it

Add <case is="value"> with what to show for it, or end the match with <case else> for every value you have not named.

In a terminal

duolith explain E0500

Mentioned in