From 🌎 to :globe: and back again
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.editorconfig
.gitignore
.jscsrc
.jshintignore
.jshintrc
README.md
bin.create-emoji-list.js
circle.yml
emoji.js
emoji.test.js
example.js
image.gif
library.json
package.json

README.md

Love the Pixar Shorts

NPM Version CircleCI Coverage Status

Plenty of services love to use the emoji shortcodes in plain-text markup, so this library aims to simplify that process for you, making 😎 become :sunglasses:, πŸ’‘ to :bulb:, etc. There's an amazing list of shortcodes here if you want to explore them.

This module is built using lodash.toarray@4 and github/gemoji (a big πŸ‘ to both teams for their excellent work on those). The latter has had some post-processing done, to make lookups quicker!

Usage

var emoji = require('emoji-shorts');

console.log(emoji.toPlain('These violent delights have violent ends 😈'));
// These violent delights have violent ends :smiling_imp:

console.log(emoji.toRich('The most elegant parts of me weren\'t written by you :thinking:'));
// The most elegant parts of me weren't written by you πŸ€”

Check out example.js for more πŸŽ‰

Notes