title: Replace value of key using ramda.js
body: <p>I have the following array of objects:</p>
  
  <pre><code>const originalArray = [
    {name: 'name1', value: 10},
    {name: 'name2', value: 20}
  ]
  </code></pre>
  
  <p>And the following object</p>
  
  <pre><code>names = {
    name1: 'generic_name_1',
    name2: 'generic_name_2'
  }
  </code></pre>
  
  <p>I would like the first array to be transformed like this:</p>
  
  <pre><code>[
    {name: 'generic_name_1', value: 10},
    {name: 'generic_name_2', value: 20}
  ]
  </code></pre>
  
  <p>What I have tried so far:</p>
  
  <pre><code>const replaceName = (names, obj) =&gt; {
    if(obj['name'] in names){
      obj['name'] = names[obj['name']];
    }
    return obj;
  }
  const modifiedArray = R.map(replaceName(names), originalArray)
  </code></pre>
  
  <p>Is there a more ramda-ish way to do this?</p>