loading...

re: Opinionated React - Use Status Enums Instead of Booleans VIEW POST

TOP OF THREAD FULL DISCUSSION
re: Since these are mutually dependent state items, I'd use useReducer. Or to make the code much cleaner, move all this into a separate hook that uses...
 

I agree! I mentioned in the post that I normally wound't use three separate useState calls - just wanted to illustrate the concept easily.

I do something similar to what you're mentioning - which you can read about here if you're interested 👍

dev.to/farazamiruddin/opinionated-...

code of conduct - report abuse