Skip to contents

This function starts by looking for exact matches in emoji_name. If none is found in emoji_name then it looks in emoji_keyword. emoji_keyword can produce more then 1 matches, which will lead to one being returned at random.

Usage

emoji(keyword)

Arguments

keyword

Character, either name or keyword. If more than one emoji has the specified keyword, will pick one at random.

Details

This function isn't vectorized and will thus only work with 1 keyword at a time.

Examples

emoji("smile")
#> [1] "😄"
emoji("taco")
#> [1] "🌮"

set.seed(1234)
replicate(24, emoji("clock"))
#>  [1] "🕡" "🕦" "🕤" "🕐" "🕟" "🕕" "🕒" "🕐" "🕜" "🕡" "🕧" "⏰" "🕑" "🕤" "🕦"
#> [16] "🕜" "🕕" "🕠" "🕣" "🕠" "🕥" "🕧" "🕧" "🕘"
replicate(10, emoji("flag"))
#>  [1] "🇧🇳" "🇸🇧" "🇵🇭" "🇬🇦" "🇮🇲" "🇨🇻" "🇲🇽" "🇬🇹" "🇯🇴" "🇧🇴"