Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

js extract domain from email

let email = 'xyz@gmail.com';
let getDomain = email.substring(email.indexOf('@') + 1);

console.log(getDomain); // output - gmail.com
Source by dev.to #
 
PREVIOUS NEXT
Tagged: #js #extract #domain #email
ADD COMMENT
Topic
Name
2+5 =