版本: vee-validate v3.x 设置如下: import * as rules from ‘vee-validate/dist/rules‘ ;import zh_CN from ‘vee-validate/dist/locale/zh_CN‘ for (let rule in rules) { extend(rule, { ...rules[rule], // add the rule message: zh_CN
版本: vee-validate v3.x
设置如下:
import * as rules from ‘vee-validate/dist/rules‘; import zh_CN from ‘vee-validate/dist/locale/zh_CN‘ for (let rule in rules) { extend(rule, { ...rules[rule], // add the rule message: zh_CN.messages[rule] // add its message }); }
也可引入不同的模块进行转换