7fife-backend/node_modules/underscore/modules/flatten.js

8 lines
284 B
JavaScript
Raw Permalink Normal View History

2024-03-07 13:01:44 +00:00
import _flatten from './_flatten.js';
// Flatten out an array, either recursively (by default), or up to `depth`.
// Passing `true` or `false` as `depth` means `1` or `Infinity`, respectively.
export default function flatten(array, depth) {
return _flatten(array, depth, false);
}