Conditional validation add/remove leads to null value access
muratbinerbay opened this issue · 0 comments
muratbinerbay commented
We have 2 required checkboxes in our form and if one is checked, the other is not required and vice versa.
But the if condition e.previousElementSibling.matches("label") leads to the error Cannot read properties of null (reading 'matches'). Likely because the label of a checkbox is after the input element.