array-intersection-x

Creates an array of unique values that are included in all given arrays.

MIT 22 个版本
安装
npm install array-intersection-x
yarn add array-intersection-x
pnpm add array-intersection-x
bun add array-intersection-x
README

Travis status Dependency status devDependency status npm version jsDelivr hits bettercodehub score Coverage Status

array-intersection-x

Creates an array of unique values that are included in all given arrays.

module.exports([...array])array

This method creates an array of unique values that are included in all given arrays using SameValueZero for equality comparisons. The order and references of result values are determined by the first array.

Kind: Exported function
Returns: array - Returns the new array of intersecting values.

Param Type Description
[...array] array The arrays to inspect.

Example

import intersection from 'array-intersection-x';

console.log(intersection([2, 1], [2, 3])); // => [2]
版本列表
3.1.2 2019-08-28
3.1.1 2019-08-20
3.1.0 2019-08-14
3.0.16 2019-08-05
3.0.15 2019-08-05
3.0.14 2019-07-31
3.0.13 2019-07-27
3.0.12 2019-07-27
3.0.11 2019-07-26
3.0.10 2019-07-25
3.0.9 2019-07-24
3.0.8 2019-07-24
3.0.7 2019-07-22
3.0.6 2019-07-22
3.0.5 2019-07-21
3.0.4 2019-07-19
3.0.3 2019-07-18
3.0.2 2019-07-18
3.0.1 2019-07-17
3.0.0 2019-07-16
2.0.0 2017-09-11
1.0.0 2017-08-25