I have this kind of data
$scope.data = [{
"production_list": [
{"product": "google\n"},
{"product": "stackoverflow\n"},
{"product": "angular\n"}
]
}]
How can I display it in textarea like this?
<textarea>
google
stackoverflow
angular
</textarea>
What I tried is
<tr ng-repeat="list in data">
<td>
<textarea ng-repeat="x in data.production_list">
{{x.product}}
</textarea>
</td>
</tr>
The output is
<textarea>
google
</textarea>
<textarea>
stackoverflow
</textarea>
<textarea>
angular
</textarea>
And is this a possible to have an increment? Because instead of ng-repeat its better to make it like this
<textarea value="data.production_list[$index].product">
</textarea>
however $index is not working its value is 0