Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jiri/rust-emojicons
Emoji parser for Rust :smile:
https://github.com/jiri/rust-emojicons
Last synced: 3 months ago
JSON representation
Emoji parser for Rust :smile:
- Host: GitHub
- URL: https://github.com/jiri/rust-emojicons
- Owner: jiri
- Created: 2015-01-24T02:40:47.000Z (almost 10 years ago)
- Default Branch: master
- Last Pushed: 2018-12-16T07:17:07.000Z (almost 6 years ago)
- Last Synced: 2024-07-06T19:10:52.962Z (4 months ago)
- Language: Rust
- Homepage:
- Size: 33.2 KB
- Stars: 39
- Watchers: 4
- Forks: 8
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Emojicons [![Build Status](https://travis-ci.org/jiri/rust-emojicons.svg?branch=master)](https://travis-ci.org/jiri/rust-emojicons)
Emojicons is a simple emoji parser written in Rust focused on ease of use and speed. It uses hashed map for fast lookup and compiled regular expressions for parsing strings.
## Example usage
The library is extremely straightforward to use. For transforming strings, use the formatter:
```rust
format!("{}", EmojiFormatter("Hello, :smile:!"));
```This will return "Hello! :smile:"
There is also a macro for direct access to emoji:
```rust
emoji!("cat");
```Will return a string with the glyph for :cat:.