Skip to content

Instantly share code, notes, and snippets.

@kaunjovi
Created September 13, 2016 15:27
Show Gist options
  • Save kaunjovi/859bc8c2931123487c6861a70ec9f72e to your computer and use it in GitHub Desktop.
Save kaunjovi/859bc8c2931123487c6861a70ec9f72e to your computer and use it in GitHub Desktop.
Hello world with Angular Js
<html>
<head>
<title>Hello world from Angular</title>
<script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.5.7/angular.min.js"></script>
</head>
<body>
<h1>Hello world from Angular</h1>
<div ng-app="myApp" ng-controller="myController">
<h2>{{ message }} </h2>
</div>
</body>
<script>
angular.module('myApp', [])
.controller('myController', function( $scope ){
$scope.message = 'Hello world from AngularJs.' ;
}) ;
</script>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment