npm.io
1.0.0 • Published 5 years ago

unq-arr

Licence
ISC
Version
1.0.0
Deps
0
Size
2 kB
Vulns
0
Weekly
0

unq-arr

Simple package to remove duplicates elements in arrays

Installation

using npm

npm i unq-arr

using yarn

yarn add unq-arr

Usage

const { unique } = require('unq-arr');
const arr = unique([🍉,🍉,🍇,🍇,🍓])

console.log(arr)

//  🍉,🍇,🍓

also in nested arrays

const arr = unique([[🍉,🍉,🍇],[🍇,🍓,🫐,🍈],🍒])

console.log(arr)

//  🍉,🍇,🍓,🫐,🍈,🍒

Keywords