Question: When you subscribe to the ViewModel from the View layer, why do you want to use LiveData class instead of MutableLiveData class? Select one: a.
When you subscribe to the ViewModel from the View layer, why do you want to use LiveData class instead of MutableLiveData class?
Select one:
a. Because MutableLiveData cannot be subscribed(observed) from the View layer
b. There's no difference between the LiveData and MutableLiveData classes, so you can use either of them
c. Because you cannot have get access to a MutableLiveData object
d. To prevent the View layer from changing data
e. In ViewModel layer, the data must be saved to a LiveData object instead of MutableLiveData object.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
