https://kotlinlang.org logo
#flow
Title
# flow
m

Mikael Alfredsson

04/07/2022, 9:32 AM
Is it possible to transform from SharedFlow<typeA> to SharedFlow<typeB> without introducing a new scope? A standard transform() converts it to a Flow<typeB>
j

julian

04/07/2022, 9:07 PM
Could you
shareIn
the
Flow<B>
, but provide as its parameter the same scope used to create
SharedFlow<A>
?
m

Michael Marshall

04/08/2022, 1:30 AM
there have been some issues raised about similar ideas before, but unfortunately most
StateFlow
and
SharedFlow
methods will convert them back to a
Flow
https://youtrack.jetbrains.com/issue/KT-45502
m

Mikael Alfredsson

04/11/2022, 6:24 AM
thanks for the info.
2 Views