Lazy component (preserve validation) #1288
aresofficial
started this conversation in
General
Replies: 1 comment 2 replies
-
I don't think there is a way to easily keep validations like this, as when you remove a node, it is not there anymore. One way I could think you do to something similar to this, is to have to accordion with a group that keeps the validation and values, so validations state would be from the group not the fields. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi there,
I have a lazy component (accordion). When user collapses it - I do not render the content inside it (
v-if
).All components of
myType
havevalidation: 'required'
.The issue is when I collapse my Accordion - the form state becomes
valid = true
.Unfortunately I can not use
v-show
for my purposes because the content of this accordion can be massive + there can be multiple accordions in the same form (up to 100).Is there any way to preserve validation state? Or could you recommend some workaround?
Many thanks for your answer.
Code example
Beta Was this translation helpful? Give feedback.
All reactions