-
-
Save walnashgit/e79d69ff065977b1fbb48cd13ed15b0a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class MainViewModel : ViewModel() { | |
...... | |
private val _clickCount = MutableLiveData(0) | |
val clickCount: LiveData<Int> = _clickCount | |
fun updateClick(value: Int) { | |
_clickCount.value = value | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment