Tiny vanilla JS drop-in that turns emoji in page text into text emoticons / kaomoji.
<script src="emojicon.js" defer></script>It runs on load and watches for new text incase of ajax/SPA.
- Replaces mapped emoji in text nodes (
(^_^),<3,ᕙ(≧▽≦)ᕗ, etc.) - Leaves unmapped emoji alone
- Skips
script,style,noscript, form fields,contenteditable, and code-ish tags (code,pre,kbd,samp)
Emoji are taken from Unicode's official emoji test data:
https://unicode.org/Public/emoji/latest/emoji-test.txt
emojicon.run(); // whole body
emojicon.run(someElement) // one subtreeOpen demo.html in a browser.