A Ruby gem for working with emoji unicode characters, names, and image assets in web applications.
Emoji is a Ruby gem that provides a library for working with emoji in web applications. It allows developers to easily convert between emoji unicode characters, names, and image assets, and includes APIs for replacing emoji in text with image tags. The gem integrates with Rails asset pipeline and offers configurable asset hosting.
Ruby and Rails developers building web applications that need to display, process, or manage emoji characters and assets in their user interfaces.
Developers choose this gem for its straightforward API, Rails integration, and comprehensive emoji data lookup capabilities, making it easier to handle emoji consistently across different representations.
A gem. For Emoji. For everyone. ❤
Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.
Provides APIs to find emoji by name, unicode character, or hex value, including metadata like category and localized names, as shown in the Emoji::Index examples.
Seamlessly integrates with Rails asset pipeline and configurable asset hosts, with default inheritance from Rails.asset_host, simplifying setup for Rails apps.
Supports custom asset host configuration via strings or lambda/procs, enabling CDN usage and dynamic path handling, as detailed in the Emoji Asset Host section.
Extends Ruby strings with methods like .with_emoji_images and .image_url for convenient emoji manipulation, reducing boilerplate code in user-facing features.
Optional integration with escape_utils gem can improve HTML escaping performance by 10x-100x, as benchmarks in the README indicate, though it's not required.
Relies on the Phantom Open Emoji library for data and assets, which may lack active maintenance or updates, potentially limiting emoji coverage over time.
Without escape_utils, HTML escaping uses slower pure Ruby code, causing performance bottlenecks in high-traffic applications processing large text strings.
Requires running a separate Rake task (emoji:install_assets) to install image assets, adding an extra manual step beyond standard gem installation.
Primarily targets web applications with image tag generation, making it less suitable for CLI tools or non-web Ruby projects needing emoji handling.