https://kotlinlang.org logo
#coroutines
Title
# coroutines
k

Kshitij Patil

01/05/2021, 11:53 AM
I'm emitting a state and I want it to be cleared after receiving by an observer, I'm currently using
StateFlow
and after changing the state to desired object, I immediately set it back to null. This already sounding a bad practice so could someone guide me here with which Coroutine Flow/Channel should I use?
d

Desmond Teo

01/05/2021, 1:13 PM
SharedFlow can probably help here
4 Views