> > In fact it could be shorter: > <!DOCTYPE html> <html ng-app="myApp"> <head> <meta charset="utf-8" /> <title>AngularJS</title> <script data-require="[email protected]" src="https://cdnjs.cloudflare.com/ajax/libs/angular.js/1.3.7/angular.js" data-semver="1.3.7"></script> </head> <body ng-controller="sanController"> <script> console.clear(); var sampleApp = angular.module('myApp', []); sampleApp.controller('sanController', ['$scope', '$interval', '$timeout', function($scope, $interval, $timeout) { $scope.time = 0; $interval(function() { console.log("Update time is: " + ($scope.time+=1000)); }, 1000); } ]) </script> </body> </html>
Regards -- You received this message because you are subscribed to the Google Groups "AngularJS" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/angular. For more options, visit https://groups.google.com/d/optout.
