52 lines
1.3 KiB
Markdown
52 lines
1.3 KiB
Markdown
# email-validator
|
|
A simple module to validate an e-mail address
|
|
|
|
[![travis build](https://img.shields.io/travis/manishsaraan/email-validator.svg?style=flat-square)](https://travis-ci.org/manishsaraan/email-validator)
|
|
[![version](https://img.shields.io/npm/v/email-validator.svg?style=flat-square)]((http://npm.im/email-validator))
|
|
[![downloads](https://img.shields.io/npm/dm/email-validator.svg?style=flat-square)](https://npm-stat.com/charts.html?package=email-validators&from=2015-08-01)
|
|
[![XO code style](https://img.shields.io/badge/code_style-XO-5ed9c7.svg?style=flat-square)](https://github.com/xojs/xo)
|
|
|
|
## Installation
|
|
Install via NPM:
|
|
|
|
```bash
|
|
npm install email-validator
|
|
|
|
```
|
|
|
|
## Usage
|
|
|
|
#### javascript
|
|
|
|
```javascript
|
|
|
|
var validator = require("email-validator");
|
|
|
|
validator.validate("test@email.com"); // true
|
|
|
|
```
|
|
|
|
#### TypeScript
|
|
|
|
```typescript
|
|
|
|
import * as EmailValidator from 'email-validator';
|
|
|
|
EmailValidator.validate("test@email.com"); // true
|
|
|
|
|
|
```
|
|
|
|
## Contribute
|
|
|
|
Contributions welcome! Check the ``LICENSE`` file for more info.
|
|
|
|
## Meta
|
|
|
|
* robert@cosmicrealms.com
|
|
* manish021js@gmail.com
|
|
|
|
Distributed under the unlicense public domain. See ``LICENSE`` for more information.
|
|
|
|
[https://github.com/manishsaraan/email-validator](https://github.com/manishsaraan/email-validator)
|