How to require at least one checkbox be checked using Yup and VeeValidate with Vue 3?
I am trying to ensure a user checks at least one checkbox. The web API I am calling requires at least one value be passed in an array of strings. For this example, the user must choose at least one favorite color where the web API expects at least one of red
, green
or blue
, e.g. { "colors": ["red"] }
would be valid, but { "colors": [] }
would not.