I've recently started learning angularJS and I've encountered an error that I need help with. Below is my index.html file:
<body ng-app="myApp">
<div ng-view></div>
<a href="table">click</a>
<script src="./libs/angular.js"></script>
<script src="./libs/angular-route.js"></script>
<script src="./scripts/myscript.js"></script>
</body>
And here is my script file:
var app=angular.module("myApp",['ngRoute']);
app.config(['$routeProvider',function($routeProvider){
console.log("i am routeprovider");
$routeProvider.when('/',{
templateUrl:"index.html"
}).when('/table',{
templateUrl:"..//views//firstview.html"
}).otherwise({
redirectTo: 'google.com'
})
}])
When running index.html on my local server, I'm seeing the following error in the console:
InternalError: too much recursion
Stack trace:
[object Object]
<div ng-view="" class="ng-scope">
Please take a look at the attached image for reference:
https://i.stack.imgur.com/H8mY5.png
I would appreciate any assistance in resolving this issue.