Skip to content
This repository was archived by the owner on Apr 12, 2024. It is now read-only.

Commit b7c3155

Browse files
RobertKieltypetebacondarwin
authored andcommitted
docs(tutorial/step-7): improve injector information
I attempted to tighten up the language around the DI overview so that it was clearer and more explicit. The sole responsibilities sentence was semantically jarring and I think looks better as a list. Some minor grammar improvements. Closes #7099
1 parent c0e6527 commit b7c3155

File tree

1 file changed

+11
-6
lines changed

1 file changed

+11
-6
lines changed

docs/content/tutorial/step_07.ngdoc

+11-6
Original file line numberDiff line numberDiff line change
@@ -78,12 +78,17 @@ utilize the browser's history (back and forward navigation) and bookmarks.
7878
As you {@link tutorial/step_05 noticed}, {@link guide/di dependency injection} (DI) is at the core of
7979
AngularJS, so it's important for you to understand a thing or two about how it works.
8080

81-
When the application bootstraps, Angular creates an injector that will be used for all DI stuff in
82-
this app. The injector itself doesn't know anything about what `$http` or `$route` services do, in
83-
fact it doesn't even know about the existence of these services unless it is configured with proper
84-
module definitions. The sole responsibilities of the injector are to load specified module
85-
definition(s), register all service providers defined in these modules, and when asked, inject
86-
a specified function with dependencies (services) that it lazily instantiates via their providers.
81+
When the application bootstraps, Angular creates an injector that will be used to find and inject all
82+
of the services that are required by your app. The injector itself doesn't know anything about what
83+
`$http` or `$route` services do, in fact it doesn't even know about the existence of these services
84+
unless it is configured with proper module definitions.
85+
86+
The injector only carries out the following steps :
87+
88+
* load the module definition(s) that you specify in your app
89+
* register all Providers defined in these module definitions
90+
* when asked to do so, inject a specified function and any necessary dependencies (services) that
91+
it lazily instantiates via their Providers.
8792

8893
Providers are objects that provide (create) instances of services and expose configuration APIs
8994
that can be used to control the creation and runtime behavior of a service. In case of the `$route`

0 commit comments

Comments
 (0)