giso
08/12/2019, 9:05 AMDico
08/12/2019, 9:26 AMchan.value
to get the most recent value. Conflated channel sends always succeed, therefore you can use offer
instead of send
var value
get() = chan.value
set(value) { chan.offer(value) }
chan.offer(initialValue)
in an init blockgiso
08/12/2019, 10:44 AMgildor
08/12/2019, 1:03 PM