how to merger duplicate record in array of object using javascript code example
Example: javascript merge arrays of objects without duplicates
var merged = [...initialData, ...newData.filter(d => !ids.has(d.ID))];
var merged = [...initialData, ...newData.filter(d => !ids.has(d.ID))];