Nope, the containerRef will not trigger useEffect and should not be used in the dependencies, The above example is not entirely correct. For more details, please refer to this article medium.com/@teh_builder/ref-object...
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.
Is the containnerRef supposed to change everytime the component rerenders? So the useEffect hook will execute because the change of containerRef?
Nope, the containerRef will not trigger useEffect and should not be used in the dependencies, The above example is not entirely correct. For more details, please refer to this article medium.com/@teh_builder/ref-object...