I am new in angular JS. And this is the first time I wrote a bit of code using Angular JS by watching a tutorial. But in that video tutorial the code works properly, but my code is not working. My web page is showing a blank page.
The index.html
<!DOCTYPE html>
<html ng-app xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>MTG Browser</title>
<link href="index.css" rel="stylesheet" />
<script src="angular.min.js"></script>
<script src="CardsController.js"></script>
</head>
<body ng-controller="cardsListController">
<div id="cardsList">
<div ng-repeat="card in cards" class="cardItem">
Card {{card.id}}
</div>
</div>
</body>
</html>
And the CardsController.js
var cardsListController = function ($scope) {
$scope.cards = [{ id: 1 }, { id: 2 }];
};
Please someone explain why the code is not working?