GithubHelp home page GithubHelp logo

domain-correction's Introduction

domain-correction

Provide suggested corrections to misspelt email domain names

Installation

npm install domain-correction

Usage

const domainCorrection = require('domain-correction');

// pass options to get a function to use
const correct = domainCorrection(/* additionalHosts = [], includeDefaults = true, maxEditDistance = 3 */);

// pass in user input to get suggested changes
correct('gmai.com');       // 'gmail.com'
correct('hotamil.fr');     // 'hotmail.fr'
correct('foobarmail.com'); // 'foobarmail.com'
correct('OuTlOoK.com');    // 'outlook.com'
correct('aol.com');        // 'aol.com'

Development

  • make compile to compile source code from ES6 to ES5
  • make test to run tests
  • make lint to lint files
  • make watch to automatically watch source directory for changes
  • make coverage to run the tests with a coverage report
  • make view-coverage to open the detailed report in your browser

Deployment

  1. Create a release.
  • Run make compile
  • Update package.json to increment the version number.
  • Update History.md
  • Commit this change.
  1. Create a tag.
  • git tag -a v1.2.3
  1. Push changes
  • git push --follow-tags origin master
  1. Publish to npm
  • npm publish

domain-correction's People

Contributors

spadgos avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.