JSFiddle - React, Tailwind, and code Playground

JavaScript

var array = [1, 2, 3, 4, 5, [1, 3, 2, 4, 1]];
var novoArray = [].concat.apply([], array)
console.log(novoArray);