# @writetome51/array-get-merged-arrays

> Returns multiple arrays concatenated into one array

Latest version **2.0.0** (published 2020-07-28) · MIT license · 0 weekly downloads

## Install

```sh
npm install @writetome51/array-get-merged-arrays
pnpm add @writetome51/array-get-merged-arrays
yarn add @writetome51/array-get-merged-arrays
bun add @writetome51/array-get-merged-arrays
```

## Health

**Score 20/100 (F)** — status: abandoned.

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 2.0.0 |
| Published | 2020-07-28 |
| First published | 2018-10-15 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Dependencies | 1 |
| Unpacked size | 2.5 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Steve Thompson |
| Maintainers | writetome51 |
| Keywords | array, arrays, manipulation, flatten, concat, merge |

## Links

- npm: https://www.npmjs.com/package/@writetome51/array-get-merged-arrays
- Homepage: https://github.com/writetome51/array-get-merged-arrays#readme
- npm.io page: https://npm.io/package/@writetome51/array-get-merged-arrays

## Dependencies (1)

- [error-if-not-array](https://npm.io/package/error-if-not-array.md) ^2.0.0

## Recent versions

- 2.0.0 (latest) — 2020-07-28
- 1.1.3 — 2019-04-10
- 1.1.2 — 2019-02-25
- 1.1.1 — 2018-12-07
- 1.1.0 — 2018-11-12
- 1.0.0 — 2018-10-15

## README

# getMergedArrays(arrays): any[]

Returns all arrays inside `arrays` connected into one array.  
The source array ( `arrays` ) does not get modified.

NOTICE:  This function is tested to merge up to 120,000 arrays in one call.  
If you go higher than that, you may get a 'maximum call stack' error.

## Examples
```
let theArrays = [ [1,2], [3,4], [5,6], [7,8] ];  
getMergedArrays(theArrays);  
// -->  [1,2,3,4,5,6,7,8]

// It does not flatten deeply nested arrays:
let theArrays = [ [1,2], [ [3,4], [5,6] ], [7,8] ];  
getMergedArrays(theArrays);  
// -->  [1, 2, [3,4], [5,6], 7, 8]
```

## Installation
`npm i  @writetome51/array-get-merged-arrays`

## Loading
```js
import {getMergedArrays} from '@writetome51/array-get-merged-arrays';
```

---
_Source: https://npm.io/package/@writetome51/array-get-merged-arrays · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
