I wonder how NgModule
actually affects Angular 2 injector hierarchy.
What does the hierarchy look like in an app with nested modules? Does it create a n
You should be able to investigate providers using ng.probe($0)
in the browser console. See also https://stackoverflow.com/a/35233711/217408.
You can load modules with MyModule.forRoot()
(see also https://angular.io/docs/ts/latest/guide/ngmodule.html#!#providers) to get providers added at the root level.
If you provide it in a module, then it's available to the components in this module. I haven't seen it mentioned that a module introduces a child injector explicitly but to me this looks like it has to be the case.