Skip to content

Instantly share code, notes, and snippets.

@CostaFot
Last active March 31, 2019 13:50
Show Gist options
  • Save CostaFot/402c1d088923577618d37c2bf6381239 to your computer and use it in GitHub Desktop.
Save CostaFot/402c1d088923577618d37c2bf6381239 to your computer and use it in GitHub Desktop.
/**
* The AppComponent is like a basket for your modules.
* Put all your modules here!
* Just throwing most of the stuff in AppModule for now to get things working
*/
@Singleton
@Component(
modules = [
AndroidSupportInjectionModule::class,
AppModule::class,
ActivityBuilderModule::class
]
)
// Dagger-Android specific thingy, pure copy pasta! Whatever dude
interface AppComponent : AndroidInjector<ReviewApplication> {
@Component.Builder
interface Builder {
@BindsInstance
fun application(application: Application): Builder
fun build(): AppComponent
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment