What are the downsides of setting state inside useEffect in React?
Sigiloso
Setting state inside useEffect without proper dependencies can lead to infinite re-renders or performance issues, because every time state changes, the effect runs again, creating a loop.