Here:
Logical reason:
<div ng-controller="myController" ng-repeat= "object in objectArray">
{{object.State}}
{{oject.Capital}}
</div>
As you know, ng-repeat is a multiplication of the containing tag, so there will be many controllers on the same page:
<div ng-controller="myController" ng-repeat= "object in objectArray">
lorem
ipsum
</div>
<div ng-controller="myController" ng-repeat= "object in objectArray">
lorem
ipsum
</div>
<div ng-controller="myController" ng-repeat= "object in objectArray">
lorem
ipsum
</div>
So, therefore, you cannot use them in the same tag, you must separate them, as in the second example.
The main reason:
, , , ; angular, , ng-repeat, ng-if ng-model, , .
, AngularJS , , , , ng-repeat, , , . , , , .
AngularJS .