1.1.7 • Published 6 years ago

@extra-array/contains v1.1.7

Weekly downloads
-
License
MIT
Repository
github
Last release
6 years ago

Check if an array contains another array.

const contains = require('@extra-array/contains');
// contains(<array1>, <array2>, [begin1=0], [end1], [begin2=0], [end2])

var a = ['b', 'l', 'i', 's', 's'];
var b = ['f', 'i', 's', 'h'];
contains(a, b);
// false (bliss ![c] fish)
contains(a, b, 1);
// false (liss ![c] fish)
contains(a, b, 1, 4);
// false (lis ![c] fish)
contains(a, b, 1, 4, 1);
// false (lis ![c] ish)
contains(a, b, 1, 4, 1, 3);
// true (lis [c] is)

With extra-array try Array.contains() instead.

extra-array

1.1.7

6 years ago

1.1.6

6 years ago

1.1.4

6 years ago

1.1.3

6 years ago

1.1.2

6 years ago

1.1.1

6 years ago

1.1.0

6 years ago

1.0.6

6 years ago

1.0.4

6 years ago

1.0.3

6 years ago

1.0.1

6 years ago

1.0.0

6 years ago