Roger Alsing Roger Alsing - 1 year ago 158
AngularJS Question

Is there an ng-model and input type email bug?

Is there something special going on with input type="email" and ng-model attribute?
If the input is email, then the model doesnt update.
If I change the input type to text, number or date it updates correctly.

Bug or some special magic email validation behavior that I dont understand?

Answer Source

It does some validation on then input, so you need to have entered a valid email address before it is bound to the model.

This is the regex that is used:


Basically you need to input an address that is at least