I am trying to use `DataStore` for KMM project as...
# multiplatform
r
I am trying to use
DataStore
for KMM project as a SharedPrefs Now for fetching the data gives
Flow
is there any way I can get the data as single item just like SharedPrefs do?
t
Using single() on this flow
f
If you use single() you got to be sure that there is only 1 emit otherwise it will throw an exception. In case of multiple emits you could use first() or last().