Closed gkorland closed 9 years ago
This is already works if you setup the baseUrl
in your main.js
to be scripts
.
As result, it would be very cumbersome to implement this default as I will have to load HomeController
, and only process the default controllerUrl if that fails, which might take couple hundred milliseconds. Not to mention that each one of us have a different default path. You use scripts
but I use js
.
Add a way to define a default "controllerUrl" based on the controller name.
e.g. $routeProvider.when('/', angularAMD.route({ templateUrl: 'views/home.html', controller: 'HomeController' }))
Should be like:
$routeProvider.when('/', angularAMD.route({ templateUrl: 'views/home.html', controller: 'HomeController' controllerUrl: 'scripts/homeController' }))