Hi everyone,
I recently wrote a blog on building
Plug-and-Play UI Interaction Handlers, which you can just plug into your ViewModel to reuse the interaction handling logic without duplicating any code.
I also showed how
Composition using Delegates, fail to achieve this properly.
Check it out here:
https://vaibhav3011.medium.com/handling-ui-actions-the-right-way-in-kotlin-viewmodels-119a06bb43ef
Let me know if I made any mistakes or this "Shared UI Interaction Handling" can be achieved in other ways too
Looking forward to your feedbacks.
Thanks in advance 🙌