mirror of
https://github.com/nodejs/node.git
synced 2025-05-18 19:31:09 +00:00

PR-URL: https://github.com/nodejs/io.js/pull/2286 Reviewed-By: Roman Reiss <me@silverwind.io>
29 lines
512 B
Markdown
29 lines
512 B
Markdown
# array-union [](https://travis-ci.org/sindresorhus/array-union)
|
|
|
|
> Create an array of unique values, in order, from the input arrays
|
|
|
|
|
|
## Install
|
|
|
|
```sh
|
|
$ npm install --save array-union
|
|
```
|
|
|
|
|
|
## Usage
|
|
|
|
```js
|
|
var arrayUnion = require('array-union');
|
|
|
|
arrayUnion([1, 1, 2, 3], [2, 3]);
|
|
//=> [1, 2, 3]
|
|
|
|
arrayUnion(['foo', 'foo', 'bar'], ['foo']);
|
|
//=> ['foo', 'bar']
|
|
```
|
|
|
|
|
|
## License
|
|
|
|
MIT © [Sindre Sorhus](http://sindresorhus.com)
|