Spread operator is widely used to create a new array without mutating the
original array. Below is an example.
const numbers = [1,2,3];
const numbersCopy = [...numbers];
console.log(numbers) //[1,2,3]
console.log(numbersCopy) //[1,2,3]
console.log(numbers === numbersCopy) //false
numbersCopy[0] = 999;
console.log(numbers)