<body ng-app='MainApp'>
<div ng-controller='MainCtrl'>
<div>
<div>{{text}}</div>
<button id='click_button' type='button' >Click Me</button>
</div>
</div>
</body>
var mainMod = angular.module('MainApp', []);
mainMod.controller('MainCtrl', ['$scope',
function ($scope) {
$scope.text = 'Hey';
$('#click_button').click(function(){
alert('Click!');
$scope.$apply(function(){
$scope.text = new Date();
});
});
}
]);
This Pen doesn't use any external CSS resources.