Orhan Tozan
10/27/2020, 8:57 AMBroadcastChannel
in ViewModel in order to send events, I was using the non suspend channel.offer(..) to send them, but now with SharedFlow, there seems only be the suspending emit(...)
method. Does that mean all BroadcastChannel usage's can be migrated from
events.offer(...)
to Sharedflow?
viewModelScope.launch {
events.emit(...)
}
If so, that looks like more boilerplate for simple events sending 😕bezrukov
10/27/2020, 9:00 AMtryEmit
, it's pretty the same as Channel's offer