https://developerpublish.com/how-to-flatten-a-2-d-array-in-javascript/
How to Flatten a 2-D array in JavaScript ?