Skip to content

Instantly share code, notes, and snippets.

@kimjoar
Created October 13, 2014 15:57
Show Gist options
  • Save kimjoar/558fae36cc4aa2ed5027 to your computer and use it in GitHub Desktop.
Save kimjoar/558fae36cc4aa2ed5027 to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<html ng-app="myApp">
<head>
<script src="http://ajax.googleapis.com/ajax/libs/angularjs/1.3.0-beta.1/angular.min.js"></script>
<meta charset="utf-8">
<title>JS Bin</title>
</head>
<body>
<div ng-controller="GreetingController">
<label>Name: <input type="text" ng-model="name"></label>
<h1>Hello, {{ name }}!</h1>
</div>
<script id="jsbin-javascript">
angular.module('myApp', []);
angular.module('myApp')
.controller(
'GreetingController',
function($scope) {
$scope.name = 'Default';
}
);
</script>
<script id="jsbin-source-html" type="text/html"><!DOCTYPE html>
<html ng-app="myApp">
<head>
<script src="//ajax.googleapis.com/ajax/libs/angularjs/1.3.0-beta.1/angular.min.js"><\/script>
<meta charset="utf-8">
<title>JS Bin</title>
</head>
<body>
<div ng-controller="GreetingController">
<label>Name: <input type="text" ng-model="name"></label>
<h1>Hello, {{ name }}!</h1>
</div>
</body>
</html></script>
<script id="jsbin-source-javascript" type="text/javascript">angular.module('myApp', []);
angular.module('myApp')
.controller(
'GreetingController',
function($scope) {
$scope.name = 'Default';
}
);</script></body>
</html>
angular.module('myApp', []);
angular.module('myApp')
.controller(
'GreetingController',
function($scope) {
$scope.name = 'Default';
}
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment