1array1 = [{path: "hello"}, {path: "world"}];
2array2 = [{path: "hello"}, {path: "hahah", text: "dsdsds"}];
3
4//comparing array1 and array2 and returning unmatced from array1
5
6Object.keys(array1)
7 .filter((val, index) => array1[index].path !== array2[index].path)
8 .map((val, index) => array1[index]);
9
10// output
11//[{"path": "world"}]