Array Flattening in JavaScript
Introduction
Nested arrays are one of those things that look simple at first until they aren’t.
At some point, you’ll run into data that looks like this:
const arr = [1, [2, [3, 4], 5]];
And suddenly
bhavay.hashnode.dev4 min read