difference
difference<T>(a: T[], b: T[]): T[]Source: array.ts:184
Finds the difference between two arrays
Type Parameters
T— Array element type
Parameters
a(T[]) — First arrayb(T[]) — Second array
Returns
T[]— Elements inabut not inb
Example
CODE
difference([1, 2, 3], [2, 3, 4]) // [1]