//reactivestate-compose/com.ensody.reactivestate.compose/beforeUpdate
beforeUpdate¶
[common]\
fun <T> MutableState<T>.beforeUpdate(setter: MutableState<T>.(T) -> Unit): MutableState<T>
Returns a new MutableState that calls setter before doing the actual value update.
The value is set automatically for you after setter has been called. For more control use withSetter. This can be used to wrap a State/MutableState with extra update logic.