const str = 50;
const arr1 = [20];
const arr2 = [30, 35];
const arr3 = [[10]]
const final_arr = _.concat(str, arr1, arr2, arr3);
The _.concat() method takes all the arrays and other items as parameter and combine them together to generate a final array.
Live Demo
0 Comments