Last active
August 29, 2015 14:15
-
-
Save jnbt/2295d39c25da972036ea to your computer and use it in GitHub Desktop.
Renders emojis from the emoji-cheat-sheet.com
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Renders emojis from the emoji-cheat-sheet.com | |
// Requirements: emojify.js (https://github.com/hassankhan/emojify.js) | |
// Usage: | |
// <p data-bind="message.text | emojify | raw"></p> | |
Batman.mixin(Batman.Filters, { | |
emojify: function(content){ | |
if(typeof(content) === "undefined" || content === null) | |
return undefined; | |
return emojify.replace(content); | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment