Lodash – intersection method
Syntax Of Lodash intersection method _.intersection([arrays]) Creates an array of unique values that are included in all given arrays using SameValueZero for equality comparisons Lodash - intersection method. Arguments [arrays]…