Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

javascript how to merge arrays

const arrFirst = ['string1', 'string2'];
const arrSecond = ['string3','string4'];

const newArr = [...arrFirst, ...arrSecond];

console.log(newArr);
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #javascript #merge #arrays
ADD COMMENT
Topic
Name
7+9 =