Dagger and Butter Knife vs. Android Annotations

前端 未结 8 829
抹茶落季
抹茶落季 2021-01-29 23:54

I am evaluating Dependency Injection (DI) frameworks for an Android app. The top contenders are: Dagger (with Butter Knife) and Android Annotations. I understand that Dagger an

8条回答
  •  傲寒
    傲寒 (楼主)
    2021-01-30 00:33

    Use Android Annotations or Butterknife to ease your coding. But don't go for Roboguice! Roboguice forces your activies, fragments to extend to roboguice classes. Not fun, at all!

    Dagger 2 is a much better option. You can use it along with Android Annotations if you'd like. I would just use Android Annotations for a simple app, but these days is good to work more with Dagger.

提交回复
热议问题