Skip to content

Commit d5a3145

Browse files
committed
minor #18807 [HttpKernel] Auto-register kernel as an extension (alexandre-daubois)
This PR was merged into the 5.4 branch. Discussion ---------- [HttpKernel] Auto-register kernel as an extension Fix #14278 Commits ------- e59d643 [HttpKernel] Auto-register kernel as an extension
2 parents 8797d07 + e59d643 commit d5a3145

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

configuration/micro_kernel_trait.rst

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,18 @@ Adding Interfaces to "Micro" Kernel
105105
When using the ``MicroKernelTrait``, you can also implement the
106106
``CompilerPassInterface`` to automatically register the kernel itself as a
107107
compiler pass as explained in the dedicated
108-
:ref:`compiler pass section <kernel-as-compiler-pass>`.
108+
:ref:`compiler pass section <kernel-as-compiler-pass>`. If the
109+
:class:`Symfony\\Component\\DependencyInjection\\Extension\\ExtensionInterface`
110+
is implemented when using the ``MicroKernelTrait``, then the kernel will
111+
be automatically registered as an extension. You can learn more about it in
112+
the dedicated section about
113+
:ref:`managing configuration with extensions <components-dependency-injection-extension>`.
114+
115+
.. versionadded:: 5.2
116+
117+
The automatic registration of the kernel as an extension when implementing the
118+
:class:`Symfony\\Component\\DependencyInjection\\Extension\\ExtensionInterface`
119+
was introduced in Symfony 5.2.
109120

110121
It is also possible to implement the ``EventSubscriberInterface`` to handle
111122
events directly from the kernel, again it will be registered automatically::

0 commit comments

Comments
 (0)