<html>
<head>
<title>Angular JS Auto Bootstrap Example</title>
<script src="lib/angular.js"></script>
<script>
// JavaScript Document
//module1
var app1 = angular.module("myapp1", []);
app1.contoller ("MssgController1", function ($scope) {
$scope.message = "Angular Auto Bootstrap Mssg1";
}) ;
//module2
var app2 = angular.module("myapp2", [])
app2.controller ("MssgController2", function($scope) {
$scope.message = "Angular Auto Bootstrap Mssg2";
})
//module3 dependent on module1 & module2
angular.module("myapp", ["myapp1", "myapp2"]);
</script>
</head>
<body>
<!--ANGULAR JS AUTO BOOTSTRAP PROCESS-->
<div ng-app="myapp">
<h1>
Angular JS Multiple modules auto bootstrap</h1>
<div ng-controller="MssgController1">
{{message}} </div>
<div ng-controller="MssgController2">
{{message}} </div>
</div>
</body>
</html>
Really, great post.Thank you so much
ReplyDeleteweb design hyderabad