Array.concat()
JavaScript 1.2+, JScript 3.0+ Nav4+, NES3+, IE 4+ Syntax
array.concat(arg1,…argN)
Description
The concat() method adds the elements listed in the parameter list to the end of the existing array and returns the result. The original is not changed by this method. Should any of the arguments be Array, the elements of that array are concatenated to the array that called the method.
Table 6.9 lists the argument and return values associated with this method.
Type | Item | Description |
---|---|---|
Arguments | arg1,…argN | The parameter list of the concat() method contains one or more elements to be concatenated to the end of the array. |
Returns | The original array with the new concatenated ... |
Get Pure JavaScript now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.