check what items are missing from 2 arrays code example
Example: how to compare two arrays and return the missing values
var a1 = [1,2,3,4,5,6];
var a2 = [1,3,5];
var absent = a1.filter(e=>!a2.includes(e));
console.log(absent);
var a1 = [1,2,3,4,5,6];
var a2 = [1,3,5];
var absent = a1.filter(e=>!a2.includes(e));
console.log(absent);