Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

lodash merge array of objects without duplicates

var c = _.map(a, function(obj) {
    return _.assign(obj, _.find(b, {parentId: obj.aId}));
})
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #lodash #merge #array #objects #duplicates
ADD COMMENT
Topic
Name
2+1 =