FirestoreSearchResults.builder constructor

const FirestoreSearchResults.builder({
  1. required String? tag,
  2. required String? firestoreCollectionName,
  3. required String? searchBy,
  4. int limitOfRetrievedData = 10,
  5. required List dataListFromSnapshot(
    1. QuerySnapshot<Object?>
    ),
  6. Widget builder(
    1. BuildContext,
    2. AsyncSnapshot
    )?,
  7. Widget? initialBody,
  8. Color? resultsBodyBackgroundColor = Colors.white,
  9. Key? key,
})

Returns the results from firestore and displays the data using builder function provided by the developer This widget can be used anywhere is the widget tree, and the results will correspond the searchQuery of FirestoreSearchBar linked by tag parameter

Implementation

const FirestoreSearchResults.builder(
    {
      required this.tag,
    required this.firestoreCollectionName,
    required this.searchBy,
    this.limitOfRetrievedData = 10,
    required this.dataListFromSnapshot,
    this.builder,
    this.initialBody,
    this.resultsBodyBackgroundColor = Colors.white,
    Key? key})
    : super(key: key);