`@switch` supports exhaustive type checking, allowing Angular to verify at compile time that all possible values of a union type are handled.
By using `@default never;`, you explicitly declare that no remaining cases should exist. If the union type is later extended and a new case is not covered by an @case, Angular’s template type checker will report an error, helping you catch missing branches early.
```angular-html
@Component({
template: `
@switch (state) {
@case ('loggedOut') {
<button>Login</button>
}
@case ('loggedIn') {
<p>Welcome back!</p>
}
@default never; // throws because `@case ('loading')` is missing