title: Populate Arrays using Lodash
body: <p>Using <a href="https://lodash.com" rel="nofollow">lodash</a>, how can I "<em>populate</em>" an array of keys using values from another array as following: </p>
  
  <pre><code>let array = [{ obj: myObject, val: 42, ref: 4 }, { val: 100, ref: 1 }];
  let refs = [{ key: 4, msg: 'Hello' }, { key: 1, msg: 'there' }]
  // populate array[i].ref with refs[i].key
  response = populate(array, refs, {key: 'ref', foreingKey: 'key'})
  
  /* 
   response = [
       { obj: myObject, val: 42, ref: { key: 4, msg: 'Hello'} }, 
       { val: 100, ref: {key: 1, msg: 'There'} }
     ];
   */
  </code></pre>
  
  <p>Actually, I'm iterating both arrays manually, but I cannot figured out how can it be done with Lodash. </p>