Join Slack
Powered by
Anybody know how to show an empty state view if Pa...
# android
i
Isaac
08/14/2020, 3:10 PM
Anybody know how to show an empty state view if PagingData has empty items? I can't seem to check the size of the items in PagingData
d
Dustin Lam
08/14/2020, 4:00 PM
To get the size of presented items you need to use APIs on the adapter / differ
Dustin Lam
08/14/2020, 4:00 PM
you're looking for
adapter.itemCount
💯 1
Dustin Lam
08/14/2020, 4:06 PM
You can do this synchronously after load by calling it in loadStateFlow
💯 1
i
Isaac
08/14/2020, 4:26 PM
Man, I owe you a cold beer
344
Views
Open in Slack
Previous
Next