Exploring Angular for the first time and attempting to create a Single Page Application (SPA). I have included the route module, which seems to be functioning properly. However, the templates are not interpreting Angular expressions as expected - for example, when including " {{ 1 + 2 }}", it simply displays the same expression instead of evaluating to "3."
Is there an additional step required to make the templates process expressions correctly?
Here is my code:
<!HTML>
<head>
<script src="angular.min.js"></script>
<script src="angular.route.js"></script>
</head>
<body ng-app="Prueba">
<div class="Contenido" ng-view></div>
</body>
<script>
angular.module('Prueba', ['ngRoute'])
.config(function($routeProvider){
$routeProvider.when('/', {
templateUrl: 'vista2.html',
controller: 'prCtrl'
})
});
</script>
</HTML>
vista2.html
<div>{{ 1+2 }}</div>