Angular has great form validation built in, but it seems like the ionic-checkbox stops that from working. I have a simple form with a submit button that stays disabled until the required fields are filled out, including a confirmation checkbox.
Means it’s not validated. I’m going to assume because an ion-checkbox isn’t even a checkbox at all, so Angular’s form validation can’t check if it’s checked…because…it’s not a checkbox. Changing my code to:
let’s validation keep on working just fine. I’m trying to understand why the ion-checkbox wouldn’t put like a hidden checkbox on screen so validation could work. Any idea? I haven’t seen any open bugs on this, has anyone else experienced this?
Thank you, I haven’t messed with reactive forms yet, but we may end up making the switch for a different validation reason.
Good info. For the time being I simply disable my submit button until the form is valid and the value bound to the checkbox is true. Shouldn’t be necessary but works for now. Thanks again for the info, this is very good to know.