Validating email address in JavaScript
Webapps often ask users to input email addresses for authentication or referrals. To provide good experiences, it is always a good idea to validate email addresses before actually using it, such as to check for typo in UI to give immediate feedback or to verify…