Vuelidate's required verification page is verified as soon as it is refreshed?

I don"t know why. "Please enter your password" is displayed as soon as the page is refreshed. The code is as follows:
html section:

<div class="reg-group reg-pass">
    <label for="pass">:</label>
    <input type="text" id="pass" v-model="pass" :class="{"error":$v.pass.$error}" @blur="$v.pass.$touch()">
    <span v-show="!$v.pass.required"></span>
    <span v-show="!$v.pass.minLength || !$v.pass.maxLength">6~16</span>
</div>

<div class="reg-group reg-sure-pass">
    <label for="sure-pass">:</label>
    <input type="text" id="sure-pass" v-model="surePass" @blur="$v.surePass.$touch()">
    <span v-show="!$v.surePass.required"></span>
    <span v-show="!$v.surePass.sameAs"></span>
</div>

js section:

import {required, minLength, maxLength, between, sameAs} from "vuelidate/lib/validators";
export default {
    name: "vuelidate-pri",
    data (){
        return {
            flag: "",
            name: "",
            user: "",
            age: "",
            pass: "",
            surePass: "",
            phone: "",
            status: ""
        };
    },
    validations: {
        pass: {
            required,
            minLength: minLength(6),
            maxLength: maxLength(16)
        },
        surePass: {
            required,
            sameAs: sameAs("pass")
        },
        phone: {

        }
    }
}



This is what happens when the

page is refreshed. Hurry, ask for God!

Apr.21,2021

go to the official website to check for you. There is such a question in github Show validation only after user begin input?
. Finally, an example is given as follows:
< span VIFI =" $v.form.password.$dirty & &! $v.form.password.required "> Password is required..
I tested it locally, but it really doesn't show up after adding $v.pass.dirty .
I hope I can help you.

Menu