flutter_form_builder
flutter_form_builder copied to clipboard
Access to error list strings from each field
trafficstars
Hi, How can I get a list of text errors from all fields when submit and the form is not valid? I would like to show theses errors in another widget or format.
void savePressed() async {
final form = _formKey.currentState;
if (form!.validate()) {
form.save();
} else {
**// HERE I WOULD LIKE TO HAVE ACCESS TO THE ERROR LIST**
}
}
Not at the moment, no.
We may however think of adding the feature in the future if there's demand for it. If you think this feature will be helpful to you and others at this time consider submitting a PR of the same.