Hexo helper plugin for obfuscating strings such as email addresses. Handy against web-crawlers.
npm install hexo-helper-obfuscate --save
<a href="mailto:<%- obfuscate('jdoe@example.com')" %>>Email</a>The helper will encode the characters of the string in html entities, randomly choosing between ascii and utf-8 representation. The result will look like this:
<a href="mailto:jdoe@example.com">Email</a>Make sure to use <%- obfuscate() %> and not <%= obfuscate() %> to prevent EJS from escaping the generated string.