Macro emojicons::emoji [] [src]

macro_rules! emoji {
    ($e: expr) => { ... };
}

Macro for compile-time emoji lookup

This macro will expand to the string stored in EMOJIS on compile-time. This doesn't introduce any overhead, but is useful to prevent pasting of unicode into the code.

Example

 
assert_eq!(emoji!("cat").to_string(), "\u{01F431}");