Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/markedjs/marked-mangle


https://github.com/markedjs/marked-mangle

extension marked

Last synced: 3 months ago
JSON representation

Awesome Lists containing this project

README

        

# marked-mangle

Mangle mailto links with HTML character references.

Mangling mailto links in this way is useful when you want to prevent email harvesting bots from collecting email addresses from your website, in the case that the Markdown is server-rendered. It's also useful for preventing the browser from automatically opening the user's default email client when clicking on a mailto link.

# Usage

```js
import { marked } from "marked";
import { mangle } from "marked-mangle";

// or UMD script
//
//

marked.use(mangle());

marked.parse("[email protected]");
//

[email protected]


```