I am getting data in controller as below $scope.healthData = []; //declare an empty array
$scope.init = function(){
console.log("before function");
$http({
method: 'GET',
url: ''
}).then(function successCallback(response) {
$scope.healthData = angular.toJson(response.data);
}, function errorCallback(response) {
alert("Trouble grabbing requested data.")
});
}
and I am trying to display my data in my jsp page as below : {{ x.name }}
<td>{{ x.componentStatus }}</td>
But I am getting below error in the console : Error: [ngRepeat:dupes] http://errors.angularjs.org/1.5.8/ngRepeat/dupes?p0=x%20in%20healthData&p1=string%3A%22&p2=%22 at angular.min.js:6
at XMLHttpRequest.t.onload (angular.min.js:103)
can anyone help me?