How can I make a module defined like this: ```@Mod...
# koin
b
How can I make a module defined like this:
Copy code
@Module(includes = [IDWGameModule::class])
@ComponentScan("com.xxx.game")
class GameModule {
    
}
depend on a module defined like this:
Copy code
val coreModule = module {
    @Single
    fun scope(): ScopeWrapper = ScopeWrapper(
        CoroutineScope(Job() + Dispatchers.Main),
        CoroutineScope(Job() + <http://Dispatchers.IO|Dispatchers.IO>),
        CoroutineScope(Job() + Dispatchers.Default)
    )
}
1
b
That one is doing it the opposite way where it is putting GameModule inside of core, I want to put Core inside of Game @Pedro Alberto
I guess I am trying to dynamically include a Module, but since it is an annotation it isn't going to be possible and Module::plus doesn't work as I expected.
😞 1
p
if you want to dynamic load you have to use yourKoinIntance.loadModule(yourModule)
do you have a repo where we can see a replication of what you want ?
a
yeah annotated stuff needs to be static / dynamic behavior can be done with DSL only