Does JavaScript ever optimize out unnecessary copying (e.g., with the spread operator)

后端 未结 0 1943
挽巷
挽巷 2021-01-12 10:40

I prefer using the spread operator (newArr = [...oldArr]) in order to minimize errors. Usually the old array is no longer used and the interpreter could change

相关标签:
回答
  • 消灭零回复
提交回复
热议问题