~/talk

Dagger + Anvil: Learning to Love Dependency Injection

Talkat droidcon San Francisco 2022 · 2022-06-02..06-03· [kotlin]
github:gpeal
links:none on file
slides:none on file

Anvil is a Kotlin compiler plugin that removes almost all Dagger module boilerplate by generating bindings from annotated classes, using merge component and contributes to app scope to wire modules by scope instead of manual includes. Real repos convert 98–99% of modules away, add custom generators for Retrofit and ViewModel APIs, and measure faster builds (average ~16% faster, single-module gains up to 65%) while preserving Dagger’s compile-time safety.

AI-written summary · about

  1. 0:00Introduction
  2. 7:10Dagger basics refresher
  3. 13:54Introducing Anvil
  4. 21:14Why not Hilt?
  5. 26:13Build time optimizations
  6. 31:10Custom code generation
  7. 35:42Conclusion and Q&A
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.