emoji_replace: Replace emojis in a string

View source: R/rx.R

emoji_replaceR Documentation

Replace emojis in a string

Description

Vectorised over string and replacement

Usage

emoji_replace(string, replacement)

emoji_replace_all(string, replacement)

Arguments

string

Input vector

replacement

A character vector of replacements. Should either be of length 1 or the same length as string. See stringr::str_replace() for details

Value

A character vector

Examples

emoji_replace(emoji_name[1], "_emoji_")

string <- paste(c(letters[1:4], emoji_name[1:6]), collapse = " ")

emoji_replace_all(emoji_name[1:6], "_emoji_")

emoji documentation built on Oct. 30, 2024, 9:28 a.m.