0.0.3 • Published 2 years ago

@yzfe/litemoji v0.0.3

Weekly downloads
-
License
MIT
Repository
-
Last release
2 years ago

LitEmoji 🔥

js implementation of LitEmoji

Installation

yarn add @yzfe/litemoji

Usage

import * as litemoji from '@yzfe/litemoji'

console.log(litemoji.encodeShortcode('Baby you light my 🔥! 😃'))
// 'Baby you light my :fire:! :smiley:'
console.log(litemoji.encodeHtml('Baby you light my :fire:! :smiley:'))
// 'Baby you light my 🔥! 😃'
console.log(litemoji.encodeUnicode('Baby you light my :fire:! :smiley:'))
// 'Baby you light my 🔥! 😃'
console.log(litemoji.removeEmoji('Baby you light my 🔥! 😃!!!'))
// 'Baby you light my ! !!!'

Configuration

import * as litemoji from '@yzfe/litemoji'

// Exclude specific shortcodes when converting from unicode and HTML entities
litemoji.config('excludeShortcodes', ['mobile', 'android']))

console.log(litemoji.encodeShortcode('📱'))
// ':iphone:'

Contributing

Pull requests are welcome.

License

MIT License

0.0.3

2 years ago

0.0.2

2 years ago

0.0.1

2 years ago