Should I use multiple states per screen like this:
Copy code
private var screenState by mutableStateOf(ScreenState())
private var dialogOneState by mutableStateOf(DialogOneState())
private var lazyColumnState by mutableStateOf(LazyColumnState())
or only one?
c
Colton Idle
12/04/2022, 5:04 PM
I typically would have a single "state" that included all three of those. But thats just me.
c
Csaba Szugyiczki
12/05/2022, 7:55 AM
On the other hand I would go with multiple states just like you have here in your example 😅
Csaba Szugyiczki
12/05/2022, 7:56 AM
You will have more parameters in your topmost Composable functions but you do not have to worry about merging and then separating the values of one State object