Returns elements from source array that are not in the exclude array. Preserves uniqueness and order from the source array.
difference([2, 3])([1, 2, 3, 4]);// => [1, 4] Copy
difference([2, 3])([1, 2, 3, 4]);// => [1, 4]
Element type
Array of elements to exclude
Array of elements not in exclude
Returns elements from source array that are not in the exclude array. Preserves uniqueness and order from the source array.
Example