lodash nestedobject to nested array code example
Example: how to get nested array using lodash
var result = _.map(data, item => ({id: item.id, name: item.name}));
var result = _.map(data, item => ({id: item.id, name: item.name}));