So let's say we have two arrays
const arr1 = [1, 2, 3, 4, 5];
const arr2 = [6, 7, 8, 9, 10, 4, 5,];
I want to return just the first matching value without doing two for loops. So not by taking first value from arr1 look for it in arr2 then second value ect.
I this case I would need to return 4.
Working in React/Redux enviroment without jQuery possible.