0.3.0 • Published 7 years ago

vue-che v0.3.0

Weekly downloads
66
License
-
Repository
-
Last release
7 years ago

vue-che (basic demo)

Vue.js directive-based validation plugin. Supports context-specific (i.e. passengers list) validation.

Installation

Plugin can be used either as required module, or es2015 import, or old-fashioned script tag with global var

import VueChe from 'vue-che'
Vue.use(VueChe, { // second argument is optional
	errorClass: 'has-error',
	lang: 'ru'
})

Essential example (required input)

<input v-model="mystring" v-che:MYSTRING.reqd />
<span v-html="cheErr('MYSTRING')"><!-- Here comes a default error text --></span>

Why not model-based?

Vuelidate is great enough, it just didn't exist when I needed a vue validator with context support. :)

Since now it exists, directive-based validation has only one significant advantage in my humble opinion: it's simple, therefore it's better when you have to create many forms (without need to edit a vue instances).

It's simple because it doesn't require much code: only one directive to validate field; validation messages is built-in.

0.3.0

7 years ago

0.2.12

7 years ago

0.2.11

7 years ago

0.2.10

7 years ago

0.2.9

7 years ago

0.2.8

7 years ago

0.2.7

7 years ago

0.2.5

7 years ago

0.2.4

7 years ago

0.2.3

7 years ago

0.2.2

7 years ago

0.2.1

7 years ago

0.2.0

7 years ago