subFlow

fun <T, S> StateFlow<S>.subFlow(sub: (S) -> T): StateFlow<T>

Extension function returning a sub state flow.