We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8497373 commit 1fd4f07Copy full SHA for 1fd4f07
service_container/lazy_services.rst
@@ -120,6 +120,15 @@ You can also configure laziness when your service is injected with the
120
}
121
122
123
+This attribute also allows you to define the interfaces to proxy when using
124
+laziness, and supports lazy-autowiring of intersection types::
125
+
126
+ public function __construct(
127
+ #[Autowire(service: 'foo', lazy: FooInterface::class)]
128
+ FooInterface|BarInterface $foo,
129
+ ) {
130
+ }
131
132
.. versionadded:: 6.3
133
134
The ``lazy`` argument of the ``#[Autowire()]`` attribute was introduced in
0 commit comments