MCPcopy
hub / github.com/react-component/form / flattenRegisteredFields

Method flattenRegisteredFields

src/createFieldsStore.js:32–39  ·  view source on GitHub ↗
(fields)

Source from the content-addressed store, hash-verified

30 }
31
32 flattenRegisteredFields(fields) {
33 const validFieldsName = this.getAllFieldsName();
34 return flattenFields(
35 fields,
36 path => validFieldsName.indexOf(path) >= 0,
37 'You cannot set a form field before rendering a field associated with the value.'
38 );
39 }
40
41 setFieldsInitialValue = (initialValues) => {
42 const flattenedInitialValues = this.flattenRegisteredFields(initialValues);

Callers 3

FieldsStoreClass · 0.95
setFieldsFunction · 0.80
setFieldsValueFunction · 0.80

Calls 2

getAllFieldsNameMethod · 0.95
flattenFieldsFunction · 0.90

Tested by

no test coverage detected