Feature Request: disable auto update `status`?
xuzuodong opened this issue · 1 comments
xuzuodong commented
Hello, Dalao!
When using slimeform, is it possible to pass in an options like this:
const { form, status, verify } = useForm({
form: () => ({
userName: '',
...
}),
lazy: true,
})
When lazy
is set to true, data updates in form
won't automatically cause status
to change, unless user call verify()
or status.userName.verify()
manually.
I think it can be useful if I want to verify content in a Text Input after it's done inputing, i.e. blurred.
Similar behavior can be found here: https://quasar.dev/vue-components/input#example--lazy-rules .
LittleSound commented
Looks good, maybe you can implement this feature.
I have another solution here that achieves a similar result.
You can change the v-model to v-model.lazy
Reference document: https://vuejs.org/api/built-in-directives.html#v-model