Answer
A render should calculate UI from inputs without changing external state. React can run, pause, or repeat render work, so side effects there can cause incorrect behavior.
A render should calculate UI from inputs without changing external state. React can run, pause, or repeat render work, so side effects there can cause incorrect behavior.