Skip to content
This repository has been archived by the owner on Mar 8, 2019. It is now read-only.

Correct common misspellings in an email address, based on Kicksend's Mailcheck library.

Notifications You must be signed in to change notification settings

ianstormtaylor/correct-email

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

correct-email

Correct common misspellings in an email address, based on Kicksend's Mailcheck library.

Installation

$ component install ianstormtaylor/correct-email

Example

var correct = require('correct-email');
var correction = correct('test@gmai.com');
{
  local : 'test',
  domain : 'gmail.com',
  email : 'test@gmail.com'
}

API

correct(string)

Returns a correction for the given email string, or false if nothing to correct.

correct.threshold(number)

Change the string distance threshold for matches.

correct.domains

The array of domain names to match against.

correct.tlds

The array of TLDs to match against.

License

MIT

About

Correct common misspellings in an email address, based on Kicksend's Mailcheck library.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published