spread syntax vs slice method
问题 I was trying to understand what is the difference between spread syntax vs slice method in the following approach. suppose I want to make an actual copy of an array, I can probably easily do it using spread syntax var fruits = ["Banana", "Chips" , "Orange", "Lemon", "Apple", "Mango"] var newCitrus = [...fruits] If I console.log this ["Banana", "Chips", "Orange", "Lemon", "Apple", "Mango"] but I can also create a copy of an array using the slice method. Considering the same array above, if I