guentherguenther@chaos.social
Aug 22, 2025, 9:58 AMI used to think #TypeScript's type system was a bit basic. Turns out that's not true, I'm just shit at TypeScript.
Here's a package where someone implemented exhaustive pattern matching (similar to #Rust's match expressions) as a typescript function and uses some magic type annotation stuff to make it work and raise a compile-time error if you miss a case.