android / codelab-android-dagger

Apache License 2.0
183 stars 157 forks source link

Inject Fragments before super.onAttach() #28

Closed dalinaum closed 4 years ago

dalinaum commented 4 years ago

Inject Fragments before super.onAttach() according to Dagger's documentation: https://dagger.dev/dev-guide/android.html

Fixes #25

manuelvicnt commented 4 years ago

Hi! Thanks for the PR. According to our newest guidance, it doesn't matter when you do it: https://developer.android.com/training/dependency-injection/dagger-android#injecting-activities