title: Remove a object from a JSON object list
body: <p>HTML code:</p>
  
  <pre><code>&lt;li ng-repeat="obj in objects"&gt;{{obj.name}} &lt;a ng-click="remove($index)"&gt;x&lt;/a&gt;&lt;/li&gt; 
  </code></pre>
  
  <p>JavaScript code: </p>
  
  <pre><code>$scope.remove = function(index){
      $scope.objects.splice(index, 1);
  }
  </code></pre>
  
  <p>JSON data:</p>
  
  <pre><code>{
      "0": { "name": "name1" },
      "1": { "name": "name2" }
  }
  </code></pre>
  
  <p>When <code>remove()</code> is called, I get <code>TypeError: $scope.objects.splice is not a function</code>, here I know <code>$scope.objects</code> is not an array and so <code>splice()</code> will not work.</p>
  
  <p>Is there any method to remove the selected index??</p>
  
  <p>Thanks in advance...</p>