TypeScript's Discriminated Unions and How I Began to Worry Less
If you’ve used Typescript in any real capacity, you’ve probably run into unions. Either defined in third-party libraries or your own definitions. You can define a union with almost any combination or number of types. They’re pretty simple and general...
blog.abhishekvash.xyz3 min read
Jannik Wempe
Platform Engineering Lead @hashnode | Serverless and Frontend Enthusiast
Nice post. Discriminated unions are a very handy tool to have in your TypeScript toolbelt 👍🏼