@extra-array/is-disjoint-on.min
v2.7.3
Published
Checks if arrays have no value in common.
Readme
Checks if arrays have no value in common. :running: :vhs: :package: :moon:
Alternatives: compare, map. This is part of package extra-array.
This is browserified, minified version of @extra-array/is-disjoint-on. It is exported as global variable array_isDisjointOn. CDN: unpkg, jsDelivr.
array.isDisjointOn(x, y, [fn], [ths]);
// x: an array
// y: another array
// fn: map function (v, i, x)
// ths: this argumentconst array = require('extra-array');
var x = [1, 2, 3, 4];
array.isDisjointOn(x, [2, 5]);
// false
array.isDisjointOn(x, [-2, -5]);
// true
array.isDisjointOn(x, [-2, -5], v => Math.abs(v));
// false