Can someone please help me understand what the issue is? I am new to AngularJS and may have overlooked something. Below is my simple HTML code:
<!DOCTYPE html>
<html>
<script type="text/javascript" src="angular.js"></script>
<script type="text/javascript" src="app.js"></script>
</head>
<body ng-app="myApp">
</body>
</html>
JavaScript Code:
(function(){
var app = angular.module('myApp',[]);
});
I keep encountering the following error message:
Uncaught Error: [$injector:modulerr] Failed to instantiate module myApp due to:
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.