can we load controller in angular.js dynamically using require.js OR any other way ? Kindly help me on this.
Asked
Active
Viewed 93 times
-4
-
http://www.sitepoint.com/using-requirejs-angularjs-applications/ – Narek Mamikonyan Feb 27 '15 at 06:42
1 Answers
0
Yes you. The best way I found is using angularAMD
Also check out ui-router-extras for a great sample that loads views, states and controllers dynamically using angularAMD and ui-router-extras Future States feature.
Finally, there is a good example here on StackOverflow about loading a controller with a dynamic name as well:
AngularAMD + ui-router + dynamic controller name?