Glossary: TypeScript Beyond the Basics
assertNever
A function that takes a `never` value and throws. Calling it in a `switch` default makes the compiler complain if you forget to handle a member of a union.
Glossary: TypeScript Beyond the Basics
A function that takes a `never` value and throws. Calling it in a `switch` default makes the compiler complain if you forget to handle a member of a union.