Chrome Extension

Javascript ES6 Spread Operator

var arr1 = [0, 1, 2];
var arr2 = [3, 4, 5];
arr1.push(...arr2);
console.log(arr1);
We are a bunch of lazy programmers so we developed this chrome extension
search code from your favorite search engine
Install Now
Output
"[0,1,2,3,4,5]"

Search Index Data (The code snippet can also be found with below search text)

Javascript ES6 Spread Operator
Was this helpful?
0 Comments
Open Code Manager We are hiring