I am writing a simple Flask web app, I am trying to display a simple table data on my html page with angular js , I am using ng-repeat to loop through the data , but it is not working for unknown reason , when I check on the console it does not show any error. Please help!
This is my HTML code
<tbody>
<!-- {% for user in User %}-->
<tr ng-repeat="user in User">
<td> // user.uid // </td>
<td >// user.taskname //
<input type="image" class="deleteImg" src="static/img/trash_can.png" height="15px" width="18px" name="removeId" value="{{user.uid}}" >
<input type="image" value="{{user.uid}}" src="static/img/editbtn.svg" height="15px" width="18px" name="editId">
</td>
</tr>
<!-- {% endfor %} -->
</tbody>
This is my angular code
<script>
var app = angular.module("app", []);
app.controller('myctrl', function($scope) {
$scope.myname="Howdy";
$scope.transfer= function(user) {
$scope.maintxt="kkk";
};
});
app.config(function($interpolateProvider) {
$interpolateProvider.startSymbol('//').endSymbol('//');
});
</script>
User? It doesn't seem to be in your controller.Userto Angular via Javascript manually (not recommended) or calling an API which returns your list of users.