<How to Inject field in an object module that prov...
# stackoverflow
u
How to Inject field in an object module that provides - Hilt Android I have two classes on my android project: one is an object module and the other one is providing functions to be returned in the object module. Class 1: APIModule @Module @InstallIn(SingletonComponent::class) object APIModule { @Inject lateinit var db: FirestoreDB @Singleton @SandalItems @Provides fun provideCustomItems() = db.getCustomItems("sandals") @Singleton @ShoeItems @Provides fun provideCustomItems() = db.getCustomItems("shoes") ... }...