You can add a function to String Object
//Add this wherever you like in your javascript code
String.prototype.isEmail = function() {
return !!this.match(/^\w+@[a-zA-Z_]+?\.[a-zA-Z]{2,3}$/);
}
var user_email = "test.email@example.com";
if(user_email.isEmail()) {
//Email is valid !
} else {
//Email is invalid !
}