Skip to content

Repository files navigation

Firestore DataTableSource

This package provides a DataTableSource to be used with a PaginatedDataTable that can fetch Firestore elements using a Query object and filter them in dart.

If you're looking for a quick way to display your Firestore data in a paginated data table, check out Google's official Firebase UI for Firestore. On the other hand, if you need more flexibility and customization, this package might be what you need.

Usage

For a more complete example, check the example app.

final dataSource = FirestoreDataTableSource(
  query: FirebaseFirestore.instance.collection('my-collection'),
  getDataRow: (snapshot) => DataRow(
    cells: <DataCell>[DataCell(Text(snapshot.id))],
  ),
);

...

PaginatedDataTable(
  source: dataSource,
  columns: const <DataColumn>[
    DataColumn(label: Text("Id")),
  ],
);

Additional information

To file feature requests or bugs, visit the issues page.

About

A Flutter PaginatedDataTable that can fetch Firestore documents from a Query object and filter them using a provided function.

Resources

Stars

2 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages