A simple and fastest module to validate a public e-mail address.
Install via NPM:
npm install @defensestation/public-email-validator --save
or with yarn
yarn add @defensestation/public-email-validator
import { isPublicEmail, isValidEmail } from "@defensestation/public-email-validator";
isValidEmail("[email protected]"); //true
isPublicEmail("[email protected]"); // false
Time complexity of isPublicEmail function is O(1) which makes it the fastest code to check whether an email is public or not.