Cannot Read Property '$pristine' Of Undefined When String Used As Input Name
In my form I have an ng-repeat and within that ng-repeat I have a bunch of fields. Sometimes there could be 3 fields, sometimes there might just be one. I have an angular for each
Solution 1:
Make sure that you have set unique name attribute in your input field. Here is a fiddler that can help https://jsfiddle.net/paka2/n6weLg55/
<div ng-repeat="product in products">
<input name="price_{{$index}}" type="text" ng-model="productList['price_' + $index]" required/>
</div>
Post a Comment for "Cannot Read Property '$pristine' Of Undefined When String Used As Input Name"