Last active
July 25, 2024 21:42
-
-
Save kingisaac95/2a339378df2a246b3d656ee0d47ecf65 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const validateEmail = (email) => { | |
if (!email) return false; | |
return /^[\w\-.]+@([\w-]+\.)+[\w-]{2,}$/.test(email); | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment