You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
let injector = BridgeKt.getInjector()
let helloWorld = injector.inject(clazz: PopKoIos.self) as! PopKoIos <- THIS FAILS
helloWorld.te()
I am linking my KMM module using the following command ./gradlew :kmm-core:embedAndSignAppleFrameworkForXcode but I don't see kapt running in the logs as with Android.
Am I missing something?
The text was updated successfully, but these errors were encountered:
gchristov
changed the title
Could not find Provider for this class. Did you forget to add @Injectable?
iOS: Could not find Provider for this class. Did you forget to add @Injectable?
Sep 24, 2021
gchristov
changed the title
iOS: Could not find Provider for this class. Did you forget to add @Injectable?
[SOLVED] iOS: Could not find Provider for this class. Did you forget to add @Injectable?
Sep 28, 2021
Turns out I had to do this in my iOS setup, which makes sense as iOS doesn't have access to the generated code by default I believe. Might be worth updating the docs on the README page in case this continues to be maintained 👍
val iosMain by getting {
...
kotlin.srcDir("${buildDir.absolutePath}/generated/source/kaptKotlin/")
}
I'm following the setup instructions but running into an issue trying to inject a dependency on iOS in a kotlin multiplatform project. I have:
Bridge.kt
file in my iOS source set with the following contents:PopKoIos.kt
in my common source set:AppDelegate
:I am linking my KMM module using the following command
./gradlew :kmm-core:embedAndSignAppleFrameworkForXcode
but I don't seekapt
running in the logs as with Android.Am I missing something?
The text was updated successfully, but these errors were encountered: