DEV Community

Discussion on: Cheat Sheet for Updating Objects and Arrays in React State

Collapse
 
brianl09 profile image
brianL09

The spread operator [...] creates a shallow copy and thus doesn't mutate the original state directly.