-
-
Notifications
You must be signed in to change notification settings - Fork 3.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
自定义表单组件一直报warning #1076
Comments
props: {
value: {
type: String,
- default: '',
},
}, 去除。 |
这样是可以了,期待优化下~ |
1.3.13已经优化了的,还有问题? @mkanako |
@tangjinzhou |
哦哦 这个是提醒 form 无法收集内部的默认值,如果有默认值,可以使用 initialValue,这样也不会报warning |
initialValue如果是空字符串照样warning啊 |
另外我拿我上面的例子来说,我用input封装了个组件出来 |
不设置这个事情,目前有点困难 所以加了提醒 😓 |
还是有问题,a-form-item里嵌套一个自定义组件,当设置 |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Version
1.3.13
Environment
Chrome 75
Reproduction link
https://vue.ant.design/components/form-cn/#components-form-demo-customized-form-controls
Steps to reproduce
对input做一层简单封装
使用What is actually happening?
控制台报warning:
按照提示去设置initialValue,还是有问题
What is expected?
希望能像input一样,不需要设置initialValue也正常
The text was updated successfully, but these errors were encountered: