-
-
Notifications
You must be signed in to change notification settings - Fork 5.3k
[Types of Injections] Corrections and rephrasings #21347
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: 6.4
Are you sure you want to change the base?
Conversation
Some corrections and rephrasings concerning the documentation.
@@ -1,13 +1,13 @@ | |||
Types of Injection | |||
================== | |||
|
|||
Making a class's dependencies explicit and requiring that they be injected | |||
Making a class's dependencies explicit and requiring that they must injected |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Making a class's dependencies explicit and requiring that they must injected | |
Making a class's dependencies explicit and requiring that they must be injected |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@xabbuh I corrected it.
@@ -81,17 +81,17 @@ service container configuration: | |||
Type hinting the injected object means that you can be sure that a suitable | |||
dependency has been injected. By type-hinting, you'll get a clear error | |||
immediately if an unsuitable dependency is injected. By type hinting | |||
using an interface rather than a class you can make the choice of dependency | |||
using an interface rather than a class you can make the choice of the dependency |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change looks wrong to me.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@xabbuh Finally, I deleted the "the".
|
||
There are several ways that the dependencies can be injected. Each injection | ||
point has advantages and disadvantages to consider, as well as different | ||
ways of working with them when using the service container. | ||
ways of working with when using the service container. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change looks wrong to me.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@xabbuh I finally put again them. It is ok.
into it is a good way of making a class more reusable, testable and decoupled | ||
from others. | ||
from the others. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
from the others. | |
from other parts of the code. |
Maybe like this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@xabbuh Yes, I think it is nice. I replaced with your suggestion.
Some corrections and rephrasings concerning the documentation.