Reputation: 1922
I know, that in most cases services preferable, because they are initiated directly at the call site and this approach making code more clear.
While harder to reason, what a system doing, when things are spread out over events.
Please, give some examples. Any help would be appreciated! Thanks a lot!
Upvotes: 1
Views: 216
Reputation: 44841
Listeners make sense when you create a reusable bundle/component that should not be modified by its clients but still be extensible.
Listeners don't make much sense for application code because they add a level of indirection that makes it harder to figure out what's going on.
Upvotes: 3