Warning: [antd: Form.Item] `children` is array of render props cannot have `name`.
See original GitHub issue<Form.Item
name="agreement"
valuePropName="checked"
rules={[
{ validator:(_, value) => value ? Promise.resolve() : Promise.reject('Should accept agreement') },
]}
{...tailFormItemLayout}
>
<Checkbox>
I have read the <a href="">agreement</a>
</Checkbox>
</Form.Item>
Issue Analytics
- State:
- Created 3 years ago
- Reactions:8
- Comments:8 (2 by maintainers)
Top Results From Across the Web
ant-design/ant-design-english - Gitter
Item name key when mapping over a list to create inputs: Warning: [antd: Form.Item] `children` is array of render props cannot have `name`....
Read more >[antd: Form.Item] `children` is array of render props ... - Issuehunt
Item cannot contain h5 element, has error --> index.js:1 Warning: [antd: Form.Item] `children` is array of render props cannot have `name` #27570.
Read more >[antd: Form.Item] `children` is array of render ... - CodeSandbox
[antd: Form. Item] `children` is array of render props cannot have `name` - CodeSandbox.
Read more >antd Form.Item accepts only one child - Stack Overflow
I found a solution and have a better understanding now of what is going on. From the docs (https://ant.design/components/form/#Form.Item):.
Read more >[antd: Form.Item] `children` is array of render props cannot ...
react+antd form 警告Warning: [antd: Form.Item] `children` is array of render props cannot have `name`. luffy5459 于 2020-07-14 15:01:17 发布 20913 收藏 5.
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 Free
Top 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
@xyy7260 I guess it is because data binding is tied to a Form.Item with name key and wraps only an Input. Therefore if you have additional elements alongside the Input, such as a custom label element, you’ll have to nest Form.Items. Check the documentations => https://ant.design/components/form/#components-form-demo-complex-form-control
Hello XXX, your issue has been closed because it does not conform to our issue requirements. It seems like a good answer for any issue you have no idea how to solve ???