Hi
You may want to check AMD. E.g. http://requirejs.org/docs/whyamd.html

I just combined ui-router with require.js, so most of my navigation 
views(controller+template) loaded only when user request them. 


On Monday, January 27, 2014 2:16:53 PM UTC+2, Tudor Hoinaru wrote:
>
> Quick question regarding module dependencies - if one defines a single 
> module across the application and only some controllers require a 
> particular module dependency - how can this be accomplished?
> If the dependency is declared upon creating the module, then all 
> controllers on pages that do not reference the module source code file 
> throw an error for unknown provider.
>
> Is it possible to somehow dynamically inject upon controller declaration 
> the required dependency?
>
> Any thoughts are much appreciated!
>
> Thanks,
>
> Tudor
>
>
>

-- 
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/groups/opt_out.

Reply via email to