Skip to content

Commit a57318c

Browse files
chore: add line highlights to more DI examples
Signed-off-by: Josh <[email protected]>
1 parent a73bb1d commit a57318c

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

developer_manual/basics/dependency_injection.rst

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ centralizes object creation logic.
5656
For example, consider the following pattern:
5757

5858
.. code-block:: php
59+
:emphasize-lines: 10, 14
5960
6061
/**
6162
* Without dependency injection:
@@ -77,6 +78,7 @@ For example, consider the following pattern:
7778
With dependency injection, you would instead pass the dependency into the constructor:
7879

7980
.. code-block:: php
81+
:emphasize-lines: 10, 13, 15
8082
8183
/**
8284
* Using dependency injection:
@@ -99,6 +101,7 @@ With dependency injection, you would instead pass the dependency into the constr
99101
Or, more succinctly, by using constructor property promotion (since PHP 7.4):
100102

101103
.. code-block:: php
104+
:emphasize-lines: 18
102105
103106
/**
104107
* Using dependency injection with constructor property promotion:

0 commit comments

Comments
 (0)