Patrik Åkerfeldt
09/30/2020, 9:46 AMPatrik Åkerfeldt
09/30/2020, 10:57 AMKoinComponent
with its dependencies injected. Inside our application set up fun Application.module(...)
I initiate the component like so:
val subscriber: MySubscriber by inject()
subscriber.initiate(environment)
This in turn uses the environment
to add hooks for ApplicationStarted
and ApplicationStopped
. Seems to work as expected. Is this a decent solution?