Daniele Segato
11/26/2021, 1:06 PMTextFieldValue
for forms. Say you need to control both the text and the selected state from the ViewModel.
How do you handle this scenario?Alex
11/29/2021, 9:45 AMDaniele Segato
11/29/2021, 11:04 AMAlex
12/01/2021, 1:29 PMDaniele Segato
12/01/2021, 2:52 PMAlex
12/02/2021, 9:47 AMclass ThatViewModel: ViewModel(){
val textFieldValue = MutableStateFlow("")
fun onTextChange(text: String)
fun onTextSelectionChange(selectedText: String)
}
Daniele Segato
12/02/2021, 12:38 PMAli Khaleqi Yekta
09/25/2022, 3:14 AMDaniele Segato
10/04/2022, 5:23 PM