google/dagger

Add KMP support for @HiltViewModel annotation

IsakTheHacker opened this issue · 2 comments

The team responsible for making AndroidX Lifecycle is currently making great progress on converting the library to Kotlin Multiplatform and I think we are expecting a release soon as the new version (2.8.0) is currently in beta. This update will allow us to put ViewModels in common source sets so I see a lot of value in making Hilt and the @HiltViewModel annotation compatible with KMP. I don't have the skills needed to know if this would require a major rework or not though so please tell me if this is out of scope for now.

Thank you beforehand and thanks for making one of the best dependency injection frameworks for Android!