Sorry if this may seem too basic, but I can't wrap my head around the concept of ViewModelProvider factories. Why do we need factories? And is this the only way to create viewmodels in an activity? Thanks
Okay, based on my understanding, having a factory + using the InjectorUtils is just a way to preserve the so-called "separation of concerns", since you can't take have a reference to the Repository in the View.
Sorry if this may seem too basic, but I can't wrap my head around the concept of ViewModelProvider factories. Why do we need factories? And is this the only way to create viewmodels in an activity? Thanks