itemBuilder property

(Widget Function(BuildContext, int)?) itemBuilder
final

The builder function that creates suggestion widgets for the FieldSuggestion widget.

This function takes in a BuildContext and an index and returns a widget that will be displayed as a suggestion. The index corresponds to the position of the suggestion in the suggestions list.

Example usage:

FieldSuggestion(
  itemBuilder: (context, index) {
    return Card(
      // Customize the suggestion widget as needed.
    );
  }
  ...
)

Implementation

final Widget Function(BuildContext, int)? itemBuilder;