在做表单验证,下面是代码
1 |
submitForm (formName) { |
结果出现报错
1 |
TS2339: Property 'validate' does not exist on type 'Vue | Element | Vue[] | Element[]'. |
造成这个原因是因为没有定义类型,这样改写就可以
1 |
submitForm (formName) { |
1 |
submitForm (formName) { |
1 |
TS2339: Property 'validate' does not exist on type 'Vue | Element | Vue[] | Element[]'. |
1 |
submitForm (formName) { |
近期评论