Form validation in iOS simulator not working (pattern regex)


#1

Hi guys,

I’m following the code at:

To build a form with formbuilder.

I added in a validation for one of the fields to only accept email validation:

title: ['', [Validators.required, Validators.pattern('^[a-z0-9]+(\.[_a-z0-9]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,15})$')]],

When I run in the web the vaidation works, and the button is enabled.

When I run in iOS simulator the button is never enabled, even though the form data is valid.

Removing the pattern validation works and the button is enabled.

Any tips?

Thanks,

Darbio