In antd form getFieldDecorator throw a warning not set value directly.
See original GitHub issueIts fine outside getFieldDecorator ,but not work and throw me a waring like this when palce the compoent in getFieldDecorator:
Warning: getFieldDecorator
will override value
, so please don’t set value
directly and use setFieldsValue
to set it.
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:7
Top Results From Across the Web
Form - Ant Design
High performance Form component with data scope management. Including data collection, verification, and styles.
Read more >How to show Error or Validation messages only after form is ...
The "getFieldDecorator" to specify validation rules and error messages for each field is set in this way: <Form.Item label="Title" style={{ ...
Read more >You cannot set field before registering it when set the value to ...
if field not set, warning too. so, first set field, like: form.getFieldDecorator('fieldName', { initialValue: {} }) in render(),
Read more >antd input error message | The AI Search Engine You Control
Antd throws a warning about this. warning: defaultFileList is invalid for getFieldDecorator will set fileList , please use option.initialValue instead.
Read more >npm:antd-form-builder - Skypack
Form builder for ant.design. ... property for a field, show value directly if viewWidget not defined. ... Item> and getFieldDecorators .
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I have solved this issue with a more speculative approach。
class AceEditorForForm extends React.Component { render() { return ( <div> <AceEditor {...this.props} /> </div> ); } }
TypeError: Cannot use ‘in’ operator to search for ‘value’ in undefined