Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

I'm having a hard time understanding the docs to install this awesome plugin in to nuxt. From what I understand, which I find hard to believe, you have to export all of the rules in a plugin file. I tried to export some of the rules, but nuxt didn't know what the ValidationObserver component was.

question from:https://stackoverflow.com/questions/65940703/how-to-install-and-configure-vee-validate-v4-in-nuxt

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
1.0k views
Welcome To Ask or Share your Answers For Others

1 Answer

VeeValidate v4 is not compatible with Vue 2.x, and that means it won't work with Nuxt 2.x as vee-validate (v4) is only targeting Vue 3 support.

Generally, with vee-validate v3 you do need to register your rules in a plugin file, and register the validation-observer and validation-provider globally or import them when needed.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...