Is there sth like `ReceiveChannel#distinctUntilCha...
# coroutines
p
Is there sth like
ReceiveChannel#distinctUntilChanged
?
e
If you use
Channel(Channel.CONFLATED)
, then only distinct changes will be reported
p
So the same is true for
BroadcastChannel
?
e
You should use
ConflatedBroadcastChannel
, then
p
Why?
e
It does what you are looking for — “distinct until changed”
p
Why are the channels built by
Channel
internal, but the channels built by
BroadcastChannel
public?
e
The provides an expanded API. You can read the most recently sent
value
without actually opening subscription.
p
Thanks that's was helpful.