vector / com.haroldadmin.vector / SavedStateVectorViewModel / setStateAndPersist
setStateAndPersist¶
protected fun setStateAndPersist(reducer: suspend
S
.() ->
S
):
Unit
A convenience wrapper around the setState function which runs the given reducer, and then persists the newly created state
Parameters¶
reducer
- The state reducer to create a new state from the current state