Though this solution may be simple, I'm sure this is one of those useful things that people will be Googling for and deserves its own entry on the site If only Google would be the first place to look :) Just look at the duplicates of this closed every some time.
Any support for use of regex checks for e-mails I am 100% against.
Don’t leave it to the auto-generated default messages.
Explain to your user what is wrong and suggest solutions.
If you skip the message for a validation, the default message is displayed.
Instead of as this lets the browser (and the user) know that the contents of that field need to be secured.
The password won't appear on the screen as you type and most browsers also won't 'remember' the values entered in fields as they do with other form elements.
You can tell to use any A compatible promise implemention like this: There are already many validation libraries out there today but most of them are very tightly coupled to a language or framework.
The goal of is to provide a cross framework and cross language way of validating data.
Because the input type obscures the text typed, you should let the user confirm that they haven't made a mistake.