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
The validation rules of Rule.fields applies to the fields of the nested data structure.
Instead, the document is publish-able with empty name and label fields.
Screenshots
N/A
Which versions of Sanity are you using?
(I reviewed the code related to validation, it seems that the latest code does not support the nested field validations)
Hi @blended-bram ! I'm glad you've found a workaround. I agree that the Rule.all is not working as I'd expect, and I've filed it as a bug. Thank you for reporting it!
Describe the bug
The
Rule.fields(...)
validation API does not work inside ofRule.all
for a field validation rule:To Reproduce
Expected behavior
The validation rules of
Rule.fields
applies to the fields of the nested data structure.Instead, the document is publish-able with empty name and label fields.
Screenshots
N/A
Which versions of Sanity are you using?
(I reviewed the code related to validation, it seems that the latest code does not support the nested field validations)
What operating system are you using?
N/A
Which versions of Node.js / npm are you running?
Additional context
N/A
Security issue?
N/A
The text was updated successfully, but these errors were encountered: