Sep 5, 2018 · 1 min read
var arr = ['this', 'one', 'is', 'obvious']
var arr2 = Object.assign([], arr)
console.log(arr2)(4) ["this", "one", "is", "obvious"]
In this post, you have pointed out an error,
// ERR Oh no! Did you try to put an array in me? I can only copy objects! -Object.assign()I’ve tried in Chrome, was that due to version issue & _Object.assign_ has covered this already?