I am new to Angular JS and I am wondering how routing in Angular JS couples with Spring web MVC. My spring controllers also work on requests and hence, if I am routing to the login page from my home page, like when -
$routeProvider.when(
'/', {
templateUrl : 'home/home.html',
controller : 'HomeCtrl'
})
.when(
'/login', {
templateUrl : '/login/login.html',
controller : 'LoginCtrl'
})
.when(
'/register', {
templateUrl : '/login/signup.html',
controller : 'RegisterCtrl'
});
Then even Spring will look for a controller matching the request URL, and will render a view according. But the point is, an entire view should be rendered right? So the entire page will be reloaded, won't it? This takes away the entire point of using routing in Angular. Am i thinking the wrong way? please correct me if what I am thinking is wrong.