Marc Knaup
10/13/2020, 9:47 PMstateIn
need an initial value?
I keep writing .stateIn(…, …, initialValue = null).filterNotNull()
ephemient
10/13/2020, 9:55 PMStateFlow.value
return without an initial value?Marc Knaup
10/13/2020, 9:59 PMsuspend fun value()
instead.ephemient
10/13/2020, 10:00 PMgildor
10/13/2020, 11:19 PMMarc Knaup
10/14/2020, 12:41 AMephemient
10/14/2020, 12:51 AMMarc Knaup
10/14/2020, 1:21 AM.conflate().distinctUntilChanged()
before each .shareIn
to achieve the same behavior.Marc Knaup
10/14/2020, 1:21 AMgildor
10/14/2020, 1:52 AMgildor
10/14/2020, 1:52 AMgildor
10/14/2020, 1:52 AMSo it was designed for a subset of potential use casesExactly. as any other abstraction I believe, has some use cases in mind
gildor
10/14/2020, 1:55 AMMutableSharedFlow(replay = 1, onBufferOverflow = BufferOverflow.DROP_OLDEST)
gildor
10/14/2020, 1:56 AMgildor
10/14/2020, 1:56 AM