Open razi3742 opened 2 years ago
In GithubRemoteMediator.kt
Try changing:
override suspend fun initialize(): InitializeAction {
return InitializeAction.LAUNCH_INITIAL_REFRESH
}
Use:
return InitializeAction.SKIP_INITIAL_REFRESH
InitializeAction used to control whether load with load type REFRESH will be immediately dispatched when the first PagingData is submitted:
Documentation: https://developer.android.com/reference/kotlin/androidx/paging/RemoteMediator#initialize()
Hello,
first of all thanks for this awsome work. can you please tell me why in RemoteMediator it is calling multiple page at once. how we can restrict paging library to load only first page and then we have scroll to bottom then i can next page ??