Get Unique Object Data From two array of objects in Javascript
var olddata= [ { name:“string 1”, value:“this”, other: “that” }, { name:“string 2”, value:“this”, other: “that” } ]; var newdata = [ { name:“string 1”, value:“this”, other: “that” }, { name:“string 5”, value:“this”, other: “that” }, { name:“string 4”, value:“this”, other: “that” } ]; newdata.forEach((items, index)=>{ if( olddata.findIndex(item => item.name === items.name) == –1){ …
Get Unique Object Data From two array of objects in Javascript Read More »