There are a ton of renditions on the theme of lazy loading that involve using requirejs and hanging on to config-time providers in order to sneak late-registration of components into a running angular app.
As to the future, a good place to start is Brad Green's blog entry: http://blog.angularjs.org/2014/03/angular-20.html There are various documents linked from that one in various stages of development, some already outdated, however you can find the meeting notes document to keep track of the team if you really want to keep your finger on the pulse. Of course there are also links to the code for Angular 2.0 in github as it evolves. All that said, basically the future is ES6 modules which are due to support asynchronous loading much as requirejs does today, but with the ES6 module syntactic sugar to make it much more straightforward. As far as I know dependency injection in 2.0 will be capable of accessing modules that are defined at runtime -- in fact, there will be no distinction between runtime and config time, so lazy loading should flow from that feature. As to a timeline, your guess is as good as mine :) If I'm misstating anything here I hope someone will correct me! It's tough to keep up with the Angular team despite their openness -- they move quickly! :) On Monday, May 26, 2014 6:14:47 PM UTC-7, RichardAlan wrote: > > I have a SPA application. When the index.html loads I load AngularJS and > all of the javascript my application users will use. This means that even > the basic users also get the javascript for admin users loaded to their > PCs. What I would like to do is to load some modules at a later time after > I have determined if the user is authorized as a basic, editing or admin > user. > > From what I understand lazy loading is something that is planned for a > future release of AngularJS. > > Can anyone give me an update on the status of this. Has anyone been > suggesting if the lazy loading will be based on an exisiting framework ? > Also any suggestions on how I could best do lazy loading until AngularJS > comes up with a solution? > -- You received this message because you are subscribed to the Google Groups "AngularJS" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/angular. For more options, visit https://groups.google.com/d/optout.
