I've come across many issues related to the SavedS...
# koin
d
I've come across many issues related to the SavedStateHandle parameter in ViewModels when using Koin. While I have a general understanding of the problem, I haven’t been able to find a clear solution for it. The main issue is this error:
org.koin.core.error.NoDefinitionFoundException: No definition found for type 'androidx.lifecycle.SavedStateHandle'. Check your Modules configuration and add missing type and/or qualifier!
1
q
Have you added this
koin-compose-viewmodel-navigation = { module = "io.insert-koin:koin-compose-viewmodel-navigation", version.ref = "koin" }?
d
Just added that one, but it doesn't solve the issue
q
can you share your dependenceis?
d
Maybe I should do some cleaning uo too
q
You need these for koin viewmodels with compose
Copy code
koin-compose = { module = "io.insert-koin:koin-compose", version.ref = "koin" }
koin-compose-viewmodel = { module = "io.insert-koin:koin-compose-viewmodel", version.ref = "koin" }
koin-compose-viewmodel-navigation = { module = "io.insert-koin:koin-compose-viewmodel-navigation", version.ref = "koin" }
Copy code
koin = "4.0.2"
My suggestion to use stable version of koin rather then beta