FormFieldModifier<T> constructor

const FormFieldModifier<T>({
  1. Key? key,
  2. Widget? child,
  3. Key? modifierKey,
  4. required FormFieldModifierBuilder<T> builder,
  5. FormFieldSetter<T>? onSaved,
  6. FormFieldValidator<T>? validator,
  7. T? initialValue,
  8. bool enabled = true,
  9. AutovalidateMode? autovalidateMode,
  10. String? restorationId,
})

Creates a single form field.

The builder argument must not be null.

Implementation

const FormFieldModifier({
  super.key,
  super.child,
  super.modifierKey,
  required this.builder,
  this.onSaved,
  this.validator,
  this.initialValue,
  this.enabled = true,
  AutovalidateMode? autovalidateMode,
  this.restorationId,
}) : autovalidateMode = autovalidateMode ?? AutovalidateMode.disabled;