mapAsStateFlow

fun <T, R> StateFlow<T>.mapAsStateFlow(transform: (T) -> R): StateFlow<R>

Maps one StateFlow into another, instead of loosening it to a Flow.

Parameters

transform

The transformation from one type to another