Add missing FormState element to redux-form (#37940)

* Add missing FormState element to redux-form

According to the [example](https://redux-form.com/8.2.2/examples/submitvalidation/) on the redux-form page, it is possible to have a general error field for the whole form. I confirmed this behaviour with redux-form 8.2.6.

* Correct error formState type in redux-form
This commit is contained in:
Hendrik Röhm 2019-10-01 18:27:38 +02:00 committed by Ben Lichtman
parent 05c13bad91
commit d286affc38

View File

@ -19,10 +19,11 @@ export interface FormStateMap {
export interface FormState {
registeredFields: RegisteredFieldState[];
fields?: {[name: string]: FieldState};
fields?: { [name: string]: FieldState };
values?: { [fieldName: string]: any };
active?: string;
anyTouched?: boolean;
error?: any;
submitting?: boolean;
submitErrors?: { [fieldName: string]: string };
submitFailed?: boolean;