Is it a common practice in Compose to have State c...
# compose
a
Is it a common practice in Compose to have State classes? Like Application/ApplicationState, Window/WindowState, Control/ControlState? And then, there's sort of like a state tree and a ui tree?
a
Compose is agnostic in how you handle state. However, ViewModels are common practice and you can make those hierarchical if you want. That being said. ApplicationState has a different role than a ControlState. If it is UI specific, e.g. the internal state of a control, and not related to application logic l, I’d keep it inside the components