Skip to content Skip to sidebar Skip to footer

Angularjs $routeprovider Doesn't Route Properly

So I'm new to Angular and trying to figure out how multiple routes can lead to the same view/templateUrl and controller. Here is what I've written: angular .module('mwsApp', [

Solution 1:

You cant get rid of # in local development so you need to comment this line

$locationProvider.html5Mode(true).hashPrefix("!");

But when you're on some server on production then uncomment and use it to remove the #

otherwise you'll keep getting not get error on reloads in local development

Post a Comment for "Angularjs $routeprovider Doesn't Route Properly"