本文介绍了如何在Filepond Vue上添加所需的验证?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我阅读了以下文档: https://github.com/pqina/vue-filepond
我尝试这样添加:
<FilePond
allowMultiple="true"
accepted-file-types="image/jpg, image/jpeg, application/pdf"
maxFileSize="2MB"
required="true"/>
多个,验证文件类型,最大文件有效
multiple, validation file type, max file works
但是,必选项不起作用
我该如何解决这个问题?
How can I solve this problem guys?
推荐答案
使用v-bind:required
属性的工作原理:
<form method="post" action="">
<file-pond v-bind:required="true"/>
<button type="submit">submit</button>
</form>
相关的GitHub问题: https://github.com/pqina/vue-filepond /issues/138
Related GitHub issue: https://github.com/pqina/vue-filepond/issues/138
这篇关于如何在Filepond Vue上添加所需的验证?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!