JSPM

@bemoje/arr-flatten

3.0.0
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 10
  • Score
    100M100P100Q41466F
  • License MIT

Flattens the passed array recursively.

Package Exports

  • @bemoje/arr-flatten

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@bemoje/arr-flatten) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

@bemoje/arr-flatten

Flattens the passed array recursively.

Version

NPM version

Travis CI

dependencies

Dependencies

dependencies

Stats

NPM downloads Forks

Buy Me A Beer donate button PayPal donate button

Installation

npm install @bemoje/arr-flatten
npm install --save @bemoje/arr-flatten
npm install --save-dev @bemoje/arr-flatten

Usage

import arrFlatten from '@bemoje/arr-flatten'

arrFlatten([1, [2]])
//=> [1, 2]

arrFlatten([1, [2, [3]]])
//=> [1, 2, 3]

Tests

Uses Jest to test module functionality. Run tests to get coverage details.

npm run test

API

arrFlatten

Flattens the passed array recursively.

Parameters
  • arr Array the array to flatten
Returns

Array<any>