Im working in a not good JS project, the page rendering is make with a JQuery function.
$("#sameID").html(data);
And using this the guys here can load a .html page (I know, its very bad, but this can't be changed now)
So, using this function the script make a get request on the following html page:
test.html
<div ng-app="myApp">
<h2>Todo {{1 + 1}}!</h2>
</div>
<script src="angular.js"></script>
<script src="index.js"></script>
index.js
app = angular.module('myApp', []);
But I'm always facing this error if I remove the <div ng-app="myApp">
works.
Error: [$injector:nomod] Module 'myApp' is not available! You either misspelled the module name or forgot to load it. If registering a module ensure that you specify the dependencies as the second argument.