Skip to content

randallnwf/Dagger2Recipes-ActivitiesMultibinding

 
 

Repository files navigation

Dagger2Recipes-ActivitiesMultibinding

Example app which shows how to build Activities Subcomponents Multibinding


Starting from Dagger 2.7 there is a new way of declaring Subcomponents (my @Module.subcomponents). Thanks to this we are able to decouple AppComponent from Activities Subcomponents.

Using Multibinding we can inject Activity Subcomponents builders without passign instance of AppComponent to Activities what means that finally we can test Activities decoupled from the whole Application. We are able to provide mock objects to our activity without using tools like DaggerMock.

Check blog post: Activities Multibinding in Dagger 2 for more details.

About

Example app which shows how to build Activities Subcomponents Multibinding

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Java 100.0%