In the previous post, a simple implementation of Paging 3 was described. If you do not have sufficient information about Paging 3, please see the post about the usage of Paging 3 first.
In this article: I will cover refresh and retry functions, load state adapters, loading state listener, and list separators.
You can find the full implementation of Paging 3 in my sample Github repository.
PagingDataAdapter
has refresh()
and retry()
functions in case you need to reload data or try to load after an error such as network disconnection. …
Most apps display a large list of data, however, users generally see only a small part of it, so fetching all of the list data from the network is not an optimum solution.
The Paging library is a much easier way to implement this approach. Currently, Paging 3 is available as an alpha release. If you want to use a stable version you can use Paging 2.
This post will be about Paging 3.
Senior Android Developer @Mobven