Answer
React uses state values as snapshots. Create a new object or array when updating so the next render receives the intended value and previous snapshots remain intact.
React uses state values as snapshots. Create a new object or array when updating so the next render receives the intended value and previous snapshots remain intact.