Please keep doing this, you'll have lots and lots of students/subscribers. That is a fact!! Thank you so much for this video, I will binge-watch your previous videos soon.
You are the best guide I've ever met. We can survive any interview as long as we have you.
16:51 , maybe we should use useCallback and wrap onChange(line 33) because on each re-render new reference to onChange will be created so React.memo on PresenterDropdown doesn't make any sense, it will not work as we expected. It will always re-render the component, regardless of whether other props are changed or not.
in vscode you can set "format on save" and "save on focus change", so that your code is always saved and formatted, really handy
Thank you so much for your work!
thanks for content bro
I would have used react query for data fetching, but if am I not using react query I would abstracted that fetch to a customhook together with the loading, error states. Customhooks are pretty nice to test. Also getOptions isn't in your deps array, exhaustive deps linter rule would be yelling at you. You either useCallback and put the fetch function the the deps or you define the fetch function inside the effect.
why not maintain a state with enum 'LOADING' | 'ERROR' | 'COMPLETED' ?
@therealseniordev