marked-github-emoji
v1.0.2
Published
A lightweight, zero-dependency marked extension that renders GitHub emoji shortcodes (:smile:) as native emoji
Maintainers
Readme
marked-github-emoji 
A lightweight, zero-dependency marked extension to parse GitHub-style shortcodes into native system emojis.
Cause I just want emoji shortcodes that I'm used to in my MDs...
emojis.json emoji dictionary is generated directly from https://api.github.com/emojis and https://raw.githubusercontent.com/github/gemoji/master/db/emoji.json using the npm run generate-dict script.
Support for legendary :shipit:, :suspect:, :trollface:, :octocat:, :atom: (my good old friend 😢), :electron:, etc... that get rendered as an image.
Installation
npm install marked-github-emojiUsage
import { marked } from "marked";
import { markedGithubEmoji } from "marked-github-emoji";
marked.use(markedGithubEmoji());
const html = marked.parse("Hello :rocket: :+1:");
// <p>Hello 🚀 👍</p>Hi! :wave: Bye! :wave:
License
MIT
