What is the reason for the infinite re-rendering of the component?
I would be grateful for your help. I've been sitting over the problem for a long time. Basically I'm doing a simple field check (validation).
I can't figure out why my useEffect hook is being called (I'm guessing) an infinite number of times.
Although the dependencies indicated.
I would be grateful for your help!
Found a solution. Extra dependencies were in useEffect.Anonymous
because your errorsState is an object and you update it every time in the effectEli Valdez
To place the code, please use CodePen or similar tool. Thanks you!