You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a problem to validate formfields of nested objects that are managed in the same form as the main object.
e.g. for management of tasks:
Title: Title of Task
Desc: Description of Task
step[0] Title: Title of first Step
step[0] Desc: Description of first Step
step[1] Title: Title of second Step
step[1] Desc: Description of second Step
It is no problem to send forms like this to the backend. But I cannot find a way to use the current validation method to validate the nested formfields.
Describe the solution you'd like
I think it would be great to have a notation like this for the validation of form fields:
"field": validators for simple field, as it is now
"nestedList[].field": validators applied for "field" of every item in the nested list
"nestedList[]": special array validators e.g. for requireing min/max amount of items in that list
The text was updated successfully, but these errors were encountered:
Yes, I already tried to figure out if I already can use it for my case.
Do you think it could already work?
How would I define the validation entry e.g. for step[i].title?
@Theweird How about actually trying to read this code and run it in the debugger if you don't understand it. or insert console.log ? This code is open, it is small, you can read it and figure out what it is doing
I have a problem to validate formfields of nested objects that are managed in the same form as the main object.
e.g. for management of tasks:
It is no problem to send forms like this to the backend. But I cannot find a way to use the current validation method to validate the nested formfields.
Describe the solution you'd like
I think it would be great to have a notation like this for the validation of form fields:
The text was updated successfully, but these errors were encountered: