Sha256: e81ed7f9e666046b00e8259fc110dabef37b5fa4a68c722bf9c6bf107e921651
Contents?: true
Size: 460 Bytes
Versions: 35
Compression:
Stored size: 460 Bytes
Contents
# flatten A tiny utility to flatten arrays of arrays (of arrays, etc., recursively, infinitely or to an optional depth) into a single array of non-arrays. ## example: ```js > var flatten = require('flatten'); undefined > flatten([1, [2, 3], [4, 5, 6], [7, [8, 9]], 10]) [ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 ] > flatten([1, [2, [3, [4, [5]]]]], 2) [ 1, 2, 3, [ 4, [ 5 ] ] ] ``` ## install: npm install flatten ## license: MIT/X11.
Version data entries
35 entries across 34 versions & 12 rubygems