# array-uniq

> Create an array without duplicates

Latest version **3.0.0** (published 2021-05-03) · MIT license · 0 weekly downloads

> **Better alternative:** Use [...new Set(arr)] — Consider using a lighter alternative

## Install

```sh
npm install array-uniq
pnpm add array-uniq
yarn add array-uniq
bun add array-uniq
```

## Health

**Score 43/100 (D)** — status: abandoned.

Positive: has types package; esm support; no vulnerabilities; high maintenance score; high quality score.

Warnings: low downloads.

Negative: abandoned.

## Facts

| | |
|---|---|
| Version | 3.0.0 |
| Published | 2021-05-03 |
| First published | 2014-06-13 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | separate (@types/array-uniq) |
| Module format | ESM |
| Node | >=12 |
| Dependencies | 0 |
| Unpacked size | 2.8 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 74 |
| Author | Sindre Sorhus |
| Maintainers | sindresorhus |
| Keywords | array, set, uniq, unique, duplicate, remove |

## Links

- npm: https://www.npmjs.com/package/array-uniq
- Repository: https://github.com/sindresorhus/array-uniq
- Homepage: https://github.com/sindresorhus/array-uniq#readme
- Issues: https://github.com/sindresorhus/array-uniq/issues
- Funding: https://github.com/sponsors/sindresorhus
- npm.io page: https://npm.io/package/array-uniq

## Alternatives

- [@sindresorhus/slugify](https://npm.io/package/@sindresorhus/slugify.md) — 3.7M weekly downloads
- [solid-js](https://npm.io/package/solid-js.md) — 2.7M weekly downloads
- [expo-glass-effect](https://npm.io/package/expo-glass-effect.md) — 2.5M weekly downloads
- [nanoassert](https://npm.io/package/nanoassert.md) — 780.8K weekly downloads
- [@ffmpeg/ffmpeg](https://npm.io/package/@ffmpeg/ffmpeg.md) — 529.5K weekly downloads

## Recent versions

- 3.0.0 (latest) — 2021-05-03
- 2.1.0 — 2019-04-05
- 2.0.0 — 2018-05-04
- 1.0.3 — 2016-06-16
- 1.0.2 — 2014-12-11
- 1.0.1 — 2014-09-28
- 1.0.0 — 2014-08-13
- 0.1.1 — 2014-07-15
- 0.1.0 — 2014-06-13

## README

# array-uniq

> Create an array without duplicates

## Install

```
$ npm install array-uniq
```

## Usage

```js
import arrayUniq from 'array-uniq';

arrayUniq([1, 1, 2, 3, 3]);
//=> [1, 2, 3]

arrayUniq(['foo', 'foo', 'bar', 'foo']);
//=> ['foo', 'bar']
```

---

<div align="center">
	<b>
		<a href="https://tidelift.com/subscription/pkg/npm-array-uniq?utm_source=npm-array-uniq&utm_medium=referral&utm_campaign=readme">Get professional support for this package with a Tidelift subscription</a>
	</b>
	<br>
	<sub>
		Tidelift helps make open source sustainable for maintainers while giving companies<br>assurances about security, maintenance, and licensing for their dependencies.
	</sub>
</div>

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