Switch statements leak bugs at compile time
TypeScript switch statements silently let you forget cases.
You refactored a shape type, added a new variant, and TypeScript stayed green. Your CI passed. Your deploy went out. Then a user hit a runtime branch that…