Created
February 16, 2018 02:31
-
-
Save dhilst/cc9d10b7807b0ba5c238c19dd6a665af to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| var module = angular.module('HelloWorldApp', []); | |
| module.controller('HelloWorldController', function($scope){ | |
| $scope.name = ""; | |
| $scope.greeting = "World" | |
| $scope.setName = function(){ | |
| $scope.greeting = $scope.name.toUpperCase(); | |
| }; | |
| }) |
This file contains hidden or 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> | |
| <meta charset="UTF-8"> | |
| <title>title</title> | |
| <script src="https://cdnjs.cloudflare.com/ajax/libs/angular.js/1.6.5/angular.min.js"></script> | |
| <script src="helloworld.js"></script> | |
| </head> | |
| <body ng-app="HelloWorldApp" ng-controller="HelloWorldController"> | |
| <p>Hello {{ greeting }}!!</p> | |
| <input ng-model="name" ng-keyup="setName()"> | |
| </body> | |
| </html> |
This file contains hidden or 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
| { | |
| "name": "helloworld", | |
| "version": "1.0.0", | |
| "description": "", | |
| "main": "index.js", | |
| "scripts": { | |
| "test": "echo \"Error: no test specified\" && exit 1" | |
| }, | |
| "keywords": [], | |
| "author": "", | |
| "license": "ISC", | |
| "dependencies": { | |
| "http-server": "^0.11.1" | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment