Closed jackzhu2012 closed 10 years ago
If you specify the controller in your index.html, it seems to me the default solution is to not lazy load it. In fact, since this controller is needed throughout the app's lifetime, it makes sense to build it into your main module.
Do you have some more information @seaeye777 ? It should work.
Hi @seaeye777. You can use http://plnkr.co/ to create a small demonstration of the problem you're having if you'd like to seek help with a couch-potato problem here.
We can reopen this if you want to provide a small plunker.
I am trying the sample codes, it's really nice to lazy load controllers in the routes, but failed to load the Main controller and causing error with the "ng-controller='MainCtrl'" in index.html. Is there a best practice for loading main controller for ng apps?