Currently I'm using Angular Js routing this way and it's working fine.
config(["$routeProvider", function ($routeProvider, $mdThemingProvider) {
$routeProvider
.when('/', {
templateUrl: '/templates/home.html',
controller: 'smu72Controller'
})
.when('/contact', {
templateUrl: '/templates/contact.html',
controller: 'smu72Controller'
})
.when('/objects', {
templateUrl: '/templates/objects.html',
controller: 'smu72Controller'
})
.when('/objects/:objectId', {
templateUrl: '/templates/object.html',
controller: 'smu72Controller'
})
.when('/services', {
templateUrl: '/templates/services.html',
controller: 'smu72Controller'
})
.otherwise({
redirectTo: "/"
});
}
]);
But with this code I got ugly looking and not seo friendly urls as host/index.html#sectionname, how should I change this to get route url as host/sectionname?
P.S. I'm getting templates to div with ng-view on Index.html page.