核心提示:创建一个简单的angular实例显示当前系统时间script id='others_angular_103' type='text//script当前时间:{{colok.now}};function...
创建一个简单的angular实例
显示当前系统时间
<script id="others_angular_103" type="text/javascript" class="library" src="/js/sandbox/other/angular.min.js"></script>
当前时间:{{colok.now}};
function colokcontroller($scope){ var updatecolok=function(){ $scope.colok={now:new Date()}; var updataColok=function(){ $scope.colok.now=new Date(); } setInterval(function(){ $scope.$apply(updataColok); },1000); }; updatecolok(); }