Skip to content
On this page

ValidationsInputMixin

RequiredInputMixin implements BasicInputMixin and extends it to add complex validations to complex formulary components. Check Validations Plugin to learn more about what types of validations are included and how to register new ones.

Props

  • validations: array of validations. Type Array, default [].
html
<Card>
    <Form>
        <div class="row">
            <div class="col-12 col-md-6 mb-xs-4">
                <InputText
                    name="email"
                    label="E-mail"
                    placeholder="Enter your e-mail..."
                    icon="at"
                    :validations="['not-empty', 'email']"
                />
            </div>
            <div class="col-12 col-md-6 mb-xs-4">
                <InputPassword
                    name="password"
                    label="Password"
                    placeholder="Enter a secure password..."
                    :validations="['not-empty', { name: 'min-length', params: [8] }]"
                />
            </div>
        </div>
    </Form>
</Card>