Hilt error from AppModule class can not be resolved
I am using Hilt in Android project, and after I added class for gps tracking I am getting an error:
ModuleProcessingStep was unable to process ‘com...di.AppModule’ because ‘LocationTracker’ could not be resolved.
LocationTracker class is there and imported.
Hilt error ActivityContext cannot be provided without an @Provides-annotated method
I have setup Hilt as
Hilt error ActivityContext cannot be provided without an @Provides-annotated method
I have setup Hilt as
Does Using ActivityComponent Scope in Hilt Provide the Same Dependency Instance Across All Fragments in the Activity
As we can see in the attached picture from the Google website,
The SingletonComponent will provide the same dependency instance across the application.
Is this the same for ActivityComponent? Will it provide the same dependency instance for all the fragments in that activity? I tried this code below, and I got two different IDs of the navigator instance!
Using ActivityComponent scope in hilt does it provide same dependency instance across all fragments in the activity?
So, as we can see in the attached picture from the Google website
SingletonComponent will provide the same instance across the application.
Is this the same for ActivityComponent? Will it provide the same instance for all the fragments in that activity? I tried this code below, and I got two different ids of the navigator instance