4 ms·React Conditional Rendering with Type Safety and Exhaustive Checking1 points by lloydatkinson 4y agolloydatkinson 4y agoI wanted to share this nice TypeScript pattern when using React for conditional rendering based on a union type