paginate method

void paginate({
  1. double preload = 1000,
  2. required OnLoad onLoad,
  3. required OnLoading onLoading,
})

Method to enable pagination for the associated ListView.

  • preload: The distance from the end at which preloading should be triggered.
  • onLoad: Callback to be triggered when loading more items is required.
  • onLoading: Asynchronous callback to determine if loading is in progress.

Implementation

void paginate({
  double preload = 1000,
  required OnLoad onLoad,
  required OnLoading onLoading,
}) {
  Pagination(
    controller: this,
    preload: preload,
    onLoad: onLoad,
    onLoading: onLoading,
  );
}