Dagger 2.19
ronshapiro
released this
29 Oct 18:16
·
1992 commits
to master
since this release
dagger.android
has a new format for bindingAndroidInjector.Factory
s:- Instead of returning
AndroidInjector.Factory<? extends Activity>
(orService
,Fragment
, etc), return justAndroidInjector.Factory
> - Instead of using
@ActivityKey
(or@ServiceKey
,@FragmentKey
, etc), use@ClassKey
. Thedagger.android
map keys (with the exception of@AndroidInjectionKey
are now deprecated - If you use
@ContributesAndroidInjector
, there's nothing to do. We have updated the output to match the new format - We have provided an ErrorProne refactoring for migrating to the new format of binding
AndroidInjector.Factory
s withdagger.android
. See these docs for how to apply the refactoring to your codebase if you're ondagger-compiler-2.19
. (02dc4a7) - In the next release (2.20), we will remove the old format. This will allow us to support AndroidX packages better.
- For the complete docs, visit https://google.github.io/dagger/android
- Instead of returning
- Avoid some thrown errors during Dagger compilation for invalid modules. (4df5adf)
- Some formatting fixes even when the formatter is turned off