Skip to content

Instantly share code, notes, and snippets.

@leosilvadev
Last active January 10, 2016 00:58
Show Gist options
  • Save leosilvadev/8944c299dca8f62f480d to your computer and use it in GitHub Desktop.
Save leosilvadev/8944c299dca8f62f480d to your computer and use it in GitHub Desktop.
<DOCTYPE html>
<html ng-app="contador">
<head></head>
<body>
<section ng-controller="ContadorController">
<input ng-model="numero1" type="number">
<input ng-model="numero2" type="number">
<span>{{numero1+numero2}}</span>
</section>
<script src="angular.min.js"></script>
<script>
angular.module('contador', []);
angular.module('contador').controller('ContadorController', function($scope){
$scope.numero1 = 0;
$scope.numero2 = 0;
});
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment