how Senior Devs think about React & some code refactoring

preview_player
Показать описание

------------------------------------------------------------------------------------------
👇🏼 HOW WE CAN HELP YOU

🤔 Find Your Technical Gaps With This FREE 10-Minute Technical Assessment

🚀 Get Rid Of Impostor Syndrome And Fast-track To Senior Level

------------------------------------------------------------------------------------------
Рекомендации по теме
Комментарии
Автор

🚀Find Your Technical Gaps With This FREE 10-Minute Technical Assessment

therealseniordev
Автор

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.

BST-SLYR
Автор

You are the best guide I've ever met. We can survive any interview as long as we have you.

taoseta
Автор

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.

devv
Автор

in vscode you can set "format on save" and "save on focus change", so that your code is always saved and formatted, really handy

ScrollsoftheNebulaicWhispers
Автор

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.

Cahnisama
Автор

why not maintain a state with enum 'LOADING' | 'ERROR' | 'COMPLETED' ?

rajenderkumar
welcome to shbcf.ru