Questions tagged [savedstateviewmodelfactory]

2 questions
8
votes
2 answers

SavedStateViewModelFactory constructed with empty constructor

After updating navigation component and lifecycle viewmodel version to 2.5.0-alpha01 I have got following issue. java.lang.RuntimeException: Unable to start activity ComponentInfo{com.atcc.aewp/com.atcc.aewp.activity.SplashActivity}:…
Vahe Gharibyan
  • 5,277
  • 4
  • 36
  • 47
0
votes
0 answers

Using SavedStateViewModelFactory in Fragment

I have a Timer that sends a notification when the timer is done. Clicking this notification restarts the activity, deleting all the timer information. For this reason, I decided to use saved State for View Model. class TimerViewModel(val…