See how to use the Android Architecture Component ViewModel and LiveData classes to create a ViewModel layer for your app.
This is a companion discussion topic for the original entry at https://www.kodeco.com/34930785-mvvm-on-android/lessons/6
See how to use the Android Architecture Component ViewModel and LiveData classes to create a ViewModel layer for your app.
At the timestamp 4:40 while in the CreatureActivity.kt file,
the function ViewModelProviders has been replaced with
ViewModelProvider
the new line should look like
viewModel = ViewModelProvider(this).get(CreatureViewModel::class.java)
You can also open the final version of the building the view model test file