1.0.6 • Published 7 years ago

flatible v1.0.6

Weekly downloads
2
License
MIT
Repository
github
Last release
7 years ago

flatible

build status codecov Code Climate

Iterate recursively on a multi-dimensional array

Usage

const flatible = require('flatible');
const someArray = [["one", ["two", [3, "FOUR"]]], 5];

for (let someValue of flatible(someArray)) {
  console.log(someValue);
}

Output:

one
two
3
FOUR
5