<!DOCTYPE HTML> <html xmlns:ng="http://angularjs.org"> <script type="text/javascript" src="../build/angular.js" ng:autobind></script> <script type="text/javascript"> function Cntl($route) { $route.when('/item1', {}); $route.when('/item2', {}); $route.onChange(function() { alert('change'); }); } Cntl.$inject = ['$route']; </script> <body ng:controller="Cntl"> <a href="#/item1">test</a> <a href="#/item2">test</a> </body> </html>