adding properties to an existing object inside an array
<p>I am picking an array with few object on it from an external file.</p>

<p>Using:</p>

<pre><code>app.controller('mycontroller',  function($scope, $http) { 
$http.get("file")
.then(function(response) {
    $scope.lols = response.data;     
});});
</code></pre>

<p>This will give me back something like:</p>

<pre><code> $scope.lols = [
{
    prop1: "h1",
    prop2: "h2",
},
{
    prop1: "g1",
    prop2: "g2",
},}
</code></pre>

<p>Now I want to add a prop3 in each of the objects how should I do it ? If I had the data into my js file I will do it manually but picking the data from an external file...</p>

<p>I have tried simply doing:</p>

<pre><code>app.controller('mycontroller',  function($scope, $http) { 
$http.get("file")
.then(function(response) {
    $scope.lols = response.data;
    $scope.lols.push = [
    {prop3: "h3"},
    {prop3: "g3"}
    ]
});});
</code></pre>

<p>But it has not worked...</p>

<p>Thanks for any help or link explain it.</p>

<p><strong>SOLUTION:</strong>
<a href="https://jsfiddle.net/d3c96e0z/3/" rel="nofollow">https://jsfiddle.net/d3c96e0z/3/</a></p>