I would like to be able to inject `@Composable` fu...
# koin-contributors
j
I would like to be able to inject
@Composable
functions with Koin. An use case is abstracting the navigation to use the same interface for a Multiplatform project.
For example, I have this interface and this class
message has been deleted
Then, the Koin module should be so
I checked how
rememberNavController
function creates the
NavHostController
, so
It is working on first use, but if you go back until you exit from the application and you open the app again, you got this error
Copy code
java.lang.IllegalArgumentException: SavedStateProvider with the given key is already registered
I solved temporally the problem so, invoking
invoke()
function before any
Navigation
"go to" function is invoked
Should be great we can just use something like
message has been deleted
a
We need to check how we can handle that with Compose context, & recomposition 👍
👍 1
j
Navigation artifact is using
composable
name, I think it should be the name to replace
single
for composables
Copy code
composable { someComposableFunction() }
a
clearly what I was thinking 👍