Created
October 3, 2017 11:26
-
-
Save gmittica/d89661dbbcc662025dc1cacd29a314e2 to your computer and use it in GitHub Desktop.
Angular Lesson // source http://jsbin.com/pumojig
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<script src="https://code.jquery.com/jquery.min.js"></script> | |
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css" rel="stylesheet" type="text/css" /> | |
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"></script> | |
<script src="https://rawgit.com/angular/bower-angular/master/angular.min.js"></script> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width"> | |
<title>Angular Lesson</title> | |
<style id="jsbin-css"> | |
body > .container { | |
margin-top:20px; | |
} | |
</style> | |
</head> | |
<body ng-app="myApp"> | |
<div class="container" > | |
<div class="well" ng-controller="firstCtrl"> | |
<h2>Hello {{ name }}</h2> | |
<div class="well" ng-controller="secondCtrl"> | |
<h2>Hello {{ name }}</h2> | |
</div> | |
</div> | |
<div class="well" ng-controller="secondCtrl"> | |
<h2>Hello {{ name }}</h2> | |
</div> | |
</div> | |
<script id="jsbin-javascript"> | |
angular.module("myApp", []) | |
.controller("firstCtrl", function($scope) { | |
$scope.name = "Batman"; | |
}) | |
.controller("secondCtrl", function($scope) { | |
//$scope.name = "Joker"; | |
}); | |
</script> | |
<script id="jsbin-source-html" type="text/html"><!DOCTYPE html> | |
<html> | |
<head> | |
<script src="https://code.jquery.com/jquery.min.js"><\/script> | |
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css" rel="stylesheet" type="text/css" /> | |
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"><\/script> | |
<script src="https://rawgit.com/angular/bower-angular/master/angular.min.js"><\/script> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width"> | |
<title>Angular Lesson</title> | |
</head> | |
<body ng-app="myApp"> | |
<div class="container" > | |
<div class="well" ng-controller="firstCtrl"> | |
<h2>Hello {{ name }}</h2> | |
<div class="well" ng-controller="secondCtrl"> | |
<h2>Hello {{ name }}</h2> | |
</div> | |
</div> | |
<div class="well" ng-controller="secondCtrl"> | |
<h2>Hello {{ name }}</h2> | |
</div> | |
</div> | |
</body> | |
</html> | |
</script> | |
<script id="jsbin-source-css" type="text/css">body > .container { | |
margin-top:20px; | |
}</script> | |
<script id="jsbin-source-javascript" type="text/javascript">angular.module("myApp", []) | |
.controller("firstCtrl", function($scope) { | |
$scope.name = "Batman"; | |
}) | |
.controller("secondCtrl", function($scope) { | |
//$scope.name = "Joker"; | |
});</script></body> | |
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
body > .container { | |
margin-top:20px; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
angular.module("myApp", []) | |
.controller("firstCtrl", function($scope) { | |
$scope.name = "Batman"; | |
}) | |
.controller("secondCtrl", function($scope) { | |
//$scope.name = "Joker"; | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment