Sane Email Validation
There are lots of email address validation modules, but none of them seem to check for sane email addresses. This one does. If you don't agree, please file an issue and convince me why.
Installation
npm install sane-email-validation
Usage
const isEmail = const email = '...' if console else console
isNotEmail()
An inverted check is also exposed.
const isNotEmail = isNotEmailconst email = '...' if console else console
isAsciiEmail()
An ASCII only version of the validator.
Since internationalized email addresses are not fully supported by all infrastructure, some systems may want to limit what they consider valid. See International email and the Email Address Internationalization on Wikipedia for more information.
const isAsciiEmail = isAsciiEmailconst email = '...' if console else console
isNotAsciiEmail()
An inverted check is also exposed for the ASCII only version.
const isNotAsciiEmail = isNotAsciiEmailconst email = '...' if console else console
License
Copyright Sane Email Validation contributors. Released under the terms of the MIT license.