-
-
Notifications
You must be signed in to change notification settings - Fork 5.2k
[EventDispatcher] Document event name aliases #12420
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[EventDispatcher] Document event name aliases #12420
Conversation
a2c105e
to
4bc9fe9
Compare
Thanks a lot for this extensive documentation @derrabus! I think we won't need to document this in the components section. If there is someone that uses both these components in a standalone application and wants this behaviour, they'll probably find out how to use it themselves. We might only want to add one sentences (like For the main guide, I think the part about your custom aliases should probably be moved to a subtopic, as it's an advanced usage. But before you do anything, let's hear what @javiereguiluz thinks about that as he's busy creating a consistent structure of the documentation these weeks. |
e2f12ab
to
c87632c
Compare
Is there anything left for me to do to get this PR merged? |
@@ -246,6 +246,73 @@ there are some minor advantages for each of them: | |||
* **Listeners are more flexible** because bundles can enable or disable each of | |||
them conditionally depending on some configuration value. | |||
|
|||
.. _event-aliases: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This can be removed as it is not used and the anchor does not differ from the current headline.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just one minor, please ping me afterwards and we are good to go 🚀
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice contribution! Thank you.
@@ -220,11 +220,55 @@ determine which instance is passed. | |||
$containerBuilder->register('subscriber_service_id', \AcmeSubscriber::class) | |||
->addTag('kernel.event_subscriber'); | |||
|
|||
``RegisterListenersPass`` is able to resolve aliased class names which for |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is able to resolve
-> resolves
?
Thank you, I made the changes while merging! 👍 |
This PR was merged into the 4.4 branch. Discussion ---------- [EventDispatcher] Document event name aliases This PR fixes #12418 by documenting symfony/symfony#33793 Question: On the component's doc page, the `sidebar` block "Registering Event Listeners and Subscribers in the Service Container" has grown a bit larger with my changes. Would it make sense to move that block to a dedicated page now? Commits ------- c87632c [EventDispatcher] Document event name aliases.
* 4.4: Minor #12420 [EventDispatcher] Document event name aliases.
* 5.0: Remove old versionadded directives Minor #12420 [EventDispatcher] Document event name aliases.
Thank you, @OskarStark. 😃 |
This PR fixes #12418 by documenting symfony/symfony#33793
Question: On the component's doc page, the
sidebar
block "Registering Event Listeners and Subscribers in the Service Container" has grown a bit larger with my changes. Would it make sense to move that block to a dedicated page now?