diff --git a/service_container/tags.rst b/service_container/tags.rst index 6f85af4a945..0cb8974b8d1 100644 --- a/service_container/tags.rst +++ b/service_container/tags.rst @@ -113,6 +113,11 @@ If you want to apply tags automatically for your own services, use the ->tag('app.custom_tag'); }; +.. caution:: + + If you're using PHP, you need to call ``instanceof`` before any service + registration to make sure tags are correctly applied. + It is also possible to use the ``#[AutoconfigureTag]`` attribute directly on the base class or interface::