Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/cdepillabout/purescript-email-validate
Validating an email address string against RFC 5322
https://github.com/cdepillabout/purescript-email-validate
email email-address-val hacktoberfest purescript
Last synced: about 1 month ago
JSON representation
Validating an email address string against RFC 5322
- Host: GitHub
- URL: https://github.com/cdepillabout/purescript-email-validate
- Owner: cdepillabout
- License: bsd-3-clause
- Created: 2015-10-28T06:35:36.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2023-03-04T03:49:50.000Z (almost 2 years ago)
- Last Synced: 2024-11-11T13:50:46.861Z (about 1 month ago)
- Topics: email, email-address-val, hacktoberfest, purescript
- Language: PureScript
- Homepage:
- Size: 241 KB
- Stars: 17
- Watchers: 3
- Forks: 7
- Open Issues: 8
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
purescript-email-validate
==================[![Build
Status](https://travis-ci.org/cdepillabout/purescript-email-validate.svg)](https://travis-ci.org/cdepillabout/purescript-email-validate)A small library providing an EmailAddress type. Based on the Haskell library
[email-validate](https://hackage.haskell.org/package/email-validate).- [Module documentation](docs/Text/Email/)
### Installing
```sh
$ npm install
$ ./node_modules/.bin/bower install purescript-email-validate
```### Building / Testing
```sh
$ pulp build
$ pulp test
```### Usage
```
> import Text.Email.Validate (EmailAddress(), toString, emailAddress)
> :t emailAddress
String -> Either String EmailAddress
> emailAddress "[email protected]"
Right [email protected]
> emailAddress "bad@email@address"
Left "bad email address"
> :t toString
EmailAddress -> String
> toString $ emailAddress "[email protected]"
[email protected]
```