Hey guys, *the context*: we want to process user ...
# orbit-mvi
o
Hey guys, the context: we want to process user input from the TextField (Compose) through the state – so
onValueChange
triggers
intent
and
reduce
that creates a new state which is propagated into this TextField as a
value
; the problem: orbit seems to be too slow to reduce the text into new state object if the user taps quickly - text field shows funny text. Has anyone faced with this problem? What is your solution? Currently we gave up idea to hold the TextField text in the state of container and keep it in the Composable’s remeberSaveable
a
no solution yet... mostly tracked under https://github.com/orbit-mvi/orbit-mvi/issues/82
o
thanks for response
a
this i thought was an interesting comment... https://issuetracker.google.com/issues/200577798#comment11
o
probably is fixed in compose 1.2.0-alpha04 🤔
b
Yes, it's not a bug in Orbit, I've had this issue with another MVI framework. The only workaround I found was to let the Composable hold the state and notify the ViewModel when it changes. If you need state to be update by the business logic, you can always have your ViewModel send and
Effect
to tell the Composable to override its internal state
o
yeap, that’s what we do currently. Thanks for the explanation.. Also the other way around is to use unconfined or main intentDispatcher but doesn’t make much sense to me. Btw, compose 1.2.0-alpha05 doesn’t fix it ¯\_(ツ)_/¯