我正在尝试将此Dagger2代码转换为Koin,但是我对过程失去了主意。我需要一些帮助。
ps:我正在使用VIPER架构
Dagger2代码
import dagger.Module
import dagger.Provides
import dagger.Subcomponent
@Subcomponent (modules = [FeedModule::class])
interface FeedComponent{
fun inject(feedFragment: FeedFragment)
}
@Module
class FeedModule(private val feedPresenterOutput: FeedContracts.FeedPresenterOutput) {
@Provides
fun provideFeedPresenterInput(feedInteractorInput: FeedContracts.FeedInteractorInput) : FeedContracts.FeedPresenterInput{
val feedPresenter = FeedPresenter(feedPresenterOutput, feedInteractorInput)
feedInteractorInput.setInteractorOutput(feedPresenter)
return feedPresenter
}
}
请我需要一些帮助:)