How to group array of objects by value : <p>I'm making a data set for one of my components,
current data is</p>

<pre><code>    [ 
        {name  : "John" , id : "123"} ,
        {name  : "Josh" , id : "1234"},
        {name  : "Charlie" , id : "1234253"},
        {name  : "Charles" , id : "123345"}
    ]
</code></pre>

<p>want it to groupby like</p>

<pre><code>    {
        C : [{name:"Charlie",id:"1234253"},{name:"Charles",id:"123345"}],
        J : [{name:"John",id:"123"},{name:"Josh",id:"1234"}]
    }
</code></pre>
