DEV Community

Discussion on: Opinionated React - Use Status Enums Instead of Booleans

Collapse
 
kayis profile image
K

I think the basic idea is good, but the implementation is lacking.

An tagged union that holds the error/value would be remove quite some moving parts.

Collapse
 
farazamiruddin profile image
faraz ahmad

Nice, you're the second person to mention tagged unions to me. Looks like I need to do some learning! Thanks for the feedback! 👍

Thread Thread
 
wierdorohit123 profile image
rohit raut

Useful thing which i have learnt for the day !! Great post