Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
initValidator () {
this.validatorInstance = new WeValidator({
rules: {
phoneno: {
required: true,
mobile: true
},
code: {
required: true
},
username: {
rangeChinese: [2,8]
}
},
messages: {
phoneno: {
required: '请输入手机号',
mobile: '手机号格式不正确'