https://kotlinlang.org logo
#squarelibraries
Title
# squarelibraries
b

bnvinay92

10/15/2023, 2:40 PM
I have a molecule producing a stateflow. How can I skip emissions if a recomposition is scheduled? For example an api returns synchronously from cache and I don't want to emit the intermediary loading state.
Looked at the clock implementation. Looks like I can drop emissions while
frameSends
is not empty.
s

saket

10/15/2023, 6:48 PM
For example an api returns synchronously from cache
can this API return a
StateFlow
so that you don't have to start with a placeholder value?
b

bnvinay92

10/28/2023, 2:14 AM
Oh hey Saket how's it going 👋. Yes that's probably the right thing to do but was trying to find a shortcut.
blob smile 1
👋 1