If you use Flow, you can create your state in compose using
val state by fooFlow.collectAsState(defaultFoo)
to avoid having to put
state.value
everywhere. You can just use the state variable directly, which I find idiomatic enough. Bonus points for using a data class for state and having your state for the screen all come from a single flow.
👍 1
d
dazza5000
05/13/2022, 3:17 PM
Most of the implementation here exposes flows from the viewmodel and not a