Hi, I have a question regarding a very common use ...
# orbit-mvi
h
Hi, I have a question regarding a very common use case I would expect to be supported by the library, but I couldn't find any docs about it. Basically I need my UI State (on the ViewModel) to be updated based on external flows. This is how I would do it on a regular ViewModel
val uiState = combine(
vehiclesRepository.getAll(),
tripInProgressRepository.tripInProgress,
transform = ::mapToUiState
).stateIn(
scope = viewModelScope,
started = WhileSubscribed(5_000),
initialValue = container.stateFlow.value,
)
This way I easily receive updates from the external flows and can keep control on when they are listened and for how long. I couldn't find a way to implement this use case with orbit-mvi. I found alternatives but they are horrible lol. I was thinking about adding a
.onEach { intent { reduce { it }  } }
call before the stateIn, but I end up with 2 state holders which is not that good (container's state and this variable) but at least is easy to understand. Any ideas?