1.0.1 • Published 5 months ago

eleventy-plugin-emojify v1.0.1

Weekly downloads
-
License
MIT
Repository
github
Last release
5 months ago

eleventy-plugin-emojify

This plugin for 11ty adds an emojify filter to your templates, allowing you to use emoji markup inside them. It is inspired by the same filter found in Hugo.

Its only dependency is emojibase-data from Emojibase to serve as its data source.

Installation

npm install --save eleventy-plugin-emojify

In your .eleventy.js file, add the plugin:

// .eleventy.js
const emojifyPlugin = require('eleventy-plugin-emojify');

module.exports = function (eleventyConfig) {
    eleventyConfig.addPlugin(emojifyPlugin);
}

Usage

Simply add the emojify filter to any content, like so: {{ content | emojify | safe }}

This will transform this:

**Made with :heart:, some :robot: and Eleventy!**

To this:

<strong>Made with ❤️, some 🤖 and Eleventy!<strong>

The supported shortcode list is based on Emojibase shortcode curated list and might differ from platform to platform.

1.0.1

5 months ago

1.0.0

5 months ago