I'm a software engineer with a lot of React and startup experience. I write about my opinions on React, using Firebase with React, and lessons from building my 1st startup, Retro.
I actually tried using constants. NOT_STARTED, LOADING, etc. But enums was still better because of auto-complete and working with interfaces. Taking an enum type as the status is just more descriptive than an int, whether it's written as a constant or otherwise lol
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
I did the same! But like you said, having to remember what all the numbers represented was difficult.
I actually tried using constants. NOT_STARTED, LOADING, etc. But enums was still better because of auto-complete and working with interfaces. Taking an enum type as the status is just more descriptive than an int, whether it's written as a constant or otherwise lol