PaginateFirestore constructor
const
PaginateFirestore({
- Key? key,
- required Widget itemBuilder(
- BuildContext,
- List<
DocumentSnapshot< ,Object?> > - int
- required Query<
Object?> query, - required PaginateBuilderType itemBuilderType,
- SliverGridDelegate gridDelegate = const SliverGridDelegateWithFixedCrossAxisCount(crossAxisCount: 2),
- DocumentSnapshot<
Object?> ? startAfterDocument, - int itemsPerPage = 15,
- Widget onError()?,
- void onReachedEnd()?,
- void onLoaded()?,
- Widget onEmpty = const EmptyDisplay(),
- Widget separator = const EmptySeparator(),
- Widget initialLoader = const InitialLoader(),
- Widget bottomLoader = const BottomLoader(),
- bool shrinkWrap = false,
- bool reverse = false,
- Axis scrollDirection = Axis.vertical,
- EdgeInsets padding = const EdgeInsets.all(0),
- ScrollPhysics? physics,
- List<
ChangeNotifier> ? listeners, - ScrollController? scrollController,
- bool allowImplicitScrolling = false,
- ScrollViewKeyboardDismissBehavior keyboardDismissBehavior = ScrollViewKeyboardDismissBehavior.manual,
- PageController? pageController,
- void onPageChanged()?,
- Widget? header,
- bool isLive = false,
- bool includeMetadataChanges = false,
- GetOptions? options,
Implementation
const PaginateFirestore({
Key? key,
required this.itemBuilder,
required this.query,
required this.itemBuilderType,
this.gridDelegate =
const SliverGridDelegateWithFixedCrossAxisCount(crossAxisCount: 2),
this.startAfterDocument,
this.itemsPerPage = 15,
this.onError,
this.onReachedEnd,
this.onLoaded,
this.onEmpty = const EmptyDisplay(),
this.separator = const EmptySeparator(),
this.initialLoader = const InitialLoader(),
this.bottomLoader = const BottomLoader(),
this.shrinkWrap = false,
this.reverse = false,
this.scrollDirection = Axis.vertical,
this.padding = const EdgeInsets.all(0),
this.physics,
this.listeners,
this.scrollController,
this.allowImplicitScrolling = false,
this.keyboardDismissBehavior = ScrollViewKeyboardDismissBehavior.manual,
this.pageController,
this.onPageChanged,
this.header,
this.footer,
this.isLive = false,
this.includeMetadataChanges = false,
this.options,
}) : super(key: key);