element-hq / element-hq/element-x-android
[Architecture] Allow Activity to be injected through the dagger graph.
Open
S-Tolerable
T-Task
- Dominant language
- Kotlin
- Stars
- 2.4k
- Forks
- 624
- Avg merge
- 1d 14h
- Merged PRs (30d)
- 149
Description
We might need to inject an activity context in some of our classes used by Presenter or others.
We can trick it by using the `LocalContext.current` but it's a hack.
We should probably create a `Component` owned by `MainActivity` so we can inject it in subcomponents.
It could require to create new subcomponents for Session and Room, as the existant ones can be used outside the context of an activity (like from notification).
Contributor guide
Assessment
This issue has not been assessed yet.