Day 2: Relearning Dagger 2

rahulchowdhury

Rahul Chowdhury 🕶

Posted on July 25, 2019

Day 2: Relearning Dagger 2

It's day 2 of my job finding journey.

Where am I right now?

I started implementing a simple app using Android Architecture Components, Dagger and Kotlin.

GitHub logo rahulchowdhury / elly

Demo Android app with the new Android Jetpack 🚀components.

elly

Demo Android app with the new Android Jetpack 🚀components.




I didn't know Dagger 2 has come such a long way since I last learned to use it.

There's a whole new module called dagger.android, explicitly designed to reduce boilerplate Dagger code on Android projects.

View models now have a new trick called SavedStateHandle to reduce boilerplate while handling app state.

Turns out injecting a SavedStateHandle to a view model isn't straightforward. There's a lot to setup.

Currently, I'm stuck in making that work.

What am I doing today?

I'm going to take a step back and get accustomed to this new dagger.android module, first.

Then, I'm going to set up SavedStateHandle injection using Dagger in my app.

When all this is done, I'll be working on implementing & caching a single API call to show cool elephant profiles.

Any tips to guide me through this?

Final notes

I'm looking out for a job for the role of Android Engineer. I have over 3.5 years of experience, and either a career in Bangalore or a Remote job works for me.

💖 💪 🙅 🚩
rahulchowdhury
Rahul Chowdhury 🕶

Posted on July 25, 2019

Join Our Newsletter. No Spam, Only the good stuff.

Sign up to receive the latest update from our blog.

Related