title: Dedupe and merge fields in a collection with Lodash (or vanilla JS)
body: <p>I've been looking at this way too long and the answer's probably obvious, but I'm trying to combine a few arrays of objects.
  Given 2 arrays of objects, I need to dedupe them based on the name field, but combine the actions array:</p>
  <pre><code>var map1 = [{
      name: 'FOO',
      actions: [{bar: 'bar1'}]
  }, {
      name: 'FOO2',
      actions: [{bar: 'bar2'}]
  }]
  var map2 = [{
      name: 'FOO',
      actions: [{bar: 'bar3'}]
  }]
  </code></pre>
  <p>The desired output would be:</p>
  <pre><code>[
      {
          name: 'FOO',
          actions: [{bar: 'bar1'}, {bar: 'bar3'}] //merged by name &quot;FOO&quot;
      },
      {
          name: 'FOO2',
          actions: [{bar: 'bar2'}]
      }
  ]
  </code></pre>