I have an array filled with Float32Array
s like this:
var arr = [
new Float32Array([0.3, 0.7, 0.1]),
new Float32Array([0.2, 0.544, 0.21]),
];
console.log(arr.flat(Infinity));
How do I flatten them to be like this?:
[0.3, 0.7, 0.1, 0.2, 0.544, 0.21]
I have tried use Array.flat(Infinity)
but this still leaves the Float32Arrays
intact.