react-encoded-mailto
v0.0.6
Published
React component that obfuscates your email address to avoid bots
Maintainers
Readme
React Encoded <Mailto>
A react component to create and display a mailto link.
Getting Started
- Install with NPM -
npm install --save react-encoded-mailto
TODO
- add honeypot
Usage
var React = require('react');
var Mailto = require('react-mailto');
var Component = React.createClass({
render: function () {
return (
<Mailto email="[email protected]" obfuscate>
info(at)domain.com
</Mailto>
);
}
});Options
Property | Type | Argument | Default | Description
----------|-----------|--------------|-----------|------------
email | string | <required> | null | email address of the intended recipient.
obfuscate | boolean | <optional> | true | obfuscate email content
Developing
react-mailto is built using ES7. Run the following task to compile the src/ into dist/.
npm run buildLicense
Copyright (c) 2015 Reza Jelveh Licensed under the GPL-v2 license.
Credits
- Jason Bellamy
- Andreas Neudecker for his encodeString function
