Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 0bcf50b

Browse filesBrowse files
committed
Minor tweaks to #8502
1 parent 98a0d7e commit 0bcf50b
Copy full SHA for 0bcf50b

File tree

2 files changed

+9
-9
lines changed
Filter options

2 files changed

+9
-9
lines changed

‎console/commands_as_services.rst

Copy file name to clipboardExpand all lines: console/commands_as_services.rst
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ Or set the ``command`` attribute on the ``console.command`` tag in your service
128128
->addTag('console.command', array('command' => 'app:sunshine'))
129129
;
130130
131-
That's it. In one way or another, the ``SunshineCommand`` will be instantiated
131+
That's it. One way or another, the ``SunshineCommand`` will be instantiated
132132
only when the ``app:sunshine`` command is actually called.
133133

134134
.. note::
@@ -137,4 +137,4 @@ only when the ``app:sunshine`` command is actually called.
137137

138138
.. caution::
139139

140-
Calling the ``list`` command requires to load all commands, lazy ones included.
140+
Calling the ``list`` command will instantiate all commands, including lazy commands.

‎console/lazy_commands.rst

Copy file name to clipboardExpand all lines: console/lazy_commands.rst
+7-7Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,13 @@ How to Make Commands Lazily Loaded
77
.. note::
88

99
If you are using the Symfony full-stack framework, you are probably looking for
10-
:ref:`lazy loading of commands defined as services <console-command-service-lazy-loading>`
10+
details about :ref:`creating lazy commands <console-command-service-lazy-loading>`
1111

1212
The traditional way of adding commands to your application is to use
13-
:method:`Symfony\\Component\\Console\\Application::add` which expects a
14-
``Command`` instance as argument.
13+
:method:`Symfony\\Component\\Console\\Application::add`, which expects a
14+
``Command`` instance as an argument.
1515

16-
In order to lazy load commands, you need to register an intermediate loader
16+
In order to lazy-load commands, you need to register an intermediate loader
1717
which will be responsible for returning ``Command`` instances::
1818

1919
use AppBundle\Command\HeavyCommand;
@@ -46,7 +46,7 @@ Built-in Command Loaders
4646

4747
The :class:`Symfony\\Component\\Console\\CommandLoader\\FactoryCommandLoader`
4848
class provides a simple way of getting commands lazily loaded as it takes an
49-
array of ``Command`` factories as only constructor argument::
49+
array of ``Command`` factories as its only constructor argument::
5050

5151
use Symfony\Component\Console\CommandLoader\FactoryCommandLoader;
5252

@@ -64,8 +64,8 @@ is called.
6464

6565
The :class:`Symfony\\Component\\Console\\CommandLoader\\ContainerCommandLoader`
6666
class can be used to load commands from a PSR-11 container. As such, its
67-
constructor takes a PSR-11 ``ContainerInterface`` implementation as first
68-
argument and a command map as last argument. The command map must be an array
67+
constructor takes a PSR-11 ``ContainerInterface`` implementation as its first
68+
argument and a command map as its last argument. The command map must be an array
6969
with command names as keys and service identifiers as values::
7070

7171
use Symfony\Component\Console\CommandLoader\ContainerCommandLoader;

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.