https://kotlinlang.org logo
#dagger
Title
# dagger
j

Jason Ankers

08/20/2021, 2:58 AM
Is it possible to install dependencies in a custom component from two separate gradle modules? I.e. gradle module “app” defines an AuthComponent, and gradle module “common” needs to install some more dependencies in this component. Module “app” depends on module “common”
r

Rafal

08/20/2021, 10:11 AM
If you use Hilt it is possible to install a module into the SingletonComponent. Then your custom component can get the dependencies from the SingletonComponent since it is a direct or indirect child of it.
j

Jason Ankers

08/21/2021, 8:36 AM
@Rafal I want to install the dependencies inside my custom component, not SingletonComponent. I currently access my dependencies via an
EntryPoint
into my custom component
Solved by using multiple EntryPoints
👍 2
15 Views