Most of my work has been converting older class-based components to functional components, which means also using hooks. I think the syntax around passing useEffect which components to watch is a little weird. The distinction between [], empty, [prop] is harder to grasp than the class methods. Also useRef is a little tricky because I need to use the current property which took a little digging through the docs to realize. Overall I think they are a good way to keep functional components small and isolated.
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.
Most of my work has been converting older class-based components to functional components, which means also using hooks. I think the syntax around passing
useEffect
which components to watch is a little weird. The distinction between[], empty, [prop]
is harder to grasp than the class methods. AlsouseRef
is a little tricky because I need to use thecurrent
property which took a little digging through the docs to realize. Overall I think they are a good way to keep functional components small and isolated.