I am trying to migrate to Koin Annotations and fac...
# koin
v
I am trying to migrate to Koin Annotations and facing a problem I have this module in
commonMain
Copy code
@Module
@ComponentScan("com.medial.app.core")
internal expect class CorePlatformModule

@Module(includes = [CorePlatformModule::class])
@ComponentScan("com.medial.app.core")
class CoreModule {

    @Single
    fun connectivity() = Connectivity()
}
and these in the android and iOS SourceSet
Copy code
@Module
@ComponentScan("com.medial.app.core")
internal actual class CorePlatformModule {

    @Single
    fun amplitude(context: Context) = Amplitude(
        Configuration(
            apiKey = AppConfig.AMPLITUDE_API_KEY,
            context = context.applicationContext,
            locationListening = true,
            identifyBatchIntervalMillis = 0,
            defaultTracking = DefaultTrackingOptions(
                sessions = true,
                deepLinks = true,
                appLifecycles = true,
                screenViews = false
            )
        )
    )
}
Copy code
@Module
@ComponentScan("com.medial.app.core")
internal actual class CorePlatformModule {

    @Single
    fun amplitude() = Amplitude.instance().apply {
        initializeApiKey(AppConfig.AMPLITUDE_API_KEY)
        defaultTracking = AMPDefaultTrackingOptions().apply {
            sessions = true
            deepLinks = true
            appLifecycles = true
            screenViews = true
        }
    }
}
Now when i try to run my app, i get this error > Expect declaration
module
doesn't match actual
module
because parameter types are different Does Anyone know, why this error is showing up ?