Skip to content
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

Add KMP support for @HiltViewModel annotation #4291

Open
IsakTheHacker opened this issue Apr 25, 2024 · 1 comment
Open

Add KMP support for @HiltViewModel annotation #4291

IsakTheHacker opened this issue Apr 25, 2024 · 1 comment

Comments

@IsakTheHacker
Copy link

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!

@Chang-Eric
Copy link
Member

I just posted a response about general KMP support in #3916 (comment). In this case though, are you asking about something specific to the @HiltViewModel annotation (like just asking for that specific annotation to move to common without us providing other platform support) or just about general KMP support?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants