Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Dagger for dependency injection #36

Open
wants to merge 2 commits into
base: david/livedata
Choose a base branch
from
Open

Conversation

f2rf2r
Copy link
Member

@f2rf2r f2rf2r commented Apr 19, 2019

I stopped short of ViewModel injection and only inject up to the activity/fragment level since having Dagger work with ViewModelProvider will introduce additional complexity, especially if we also want to support passing in additional data that are outside of Dagger graph such as intent extras. Right now the Dagger setup is relatively simple while still allowing the main feature of configuring the dependency graph.

I'm planning on also creating another PR for Kodein. My plan is to have one of them to merge into master and become the default, and the other one will stay as a separate branch and periodically merge the latest changes from master.

I stopped short of ViewModel injection and only inject up to the activity/fragment level since having Dagger work with ViewModelProvider will introduce additional complexity, especially if we also want to support passing in additional data that are outside of Dagger graph such as intent extras. Right now the Dagger setup is relatively simple while still allowing the main feature of configuring the dependency graph.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant