Description Usage Arguments Examples
Alerts are typically short status messages.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 | cli_alert(text, id = NULL, class = NULL, wrap = FALSE, .envir = parent.frame())
cli_alert_success(
text,
id = NULL,
class = NULL,
wrap = FALSE,
.envir = parent.frame()
)
cli_alert_danger(
text,
id = NULL,
class = NULL,
wrap = FALSE,
.envir = parent.frame()
)
cli_alert_warning(
text,
id = NULL,
class = NULL,
wrap = FALSE,
.envir = parent.frame()
)
cli_alert_info(
text,
id = NULL,
class = NULL,
wrap = FALSE,
.envir = parent.frame()
)
|
text |
Text of the alert. |
id |
Id of the alert element. Can be used in themes. |
class |
Class of the alert element. Can be used in themes. |
wrap |
Whether to auto-wrap the text of the alert. |
.envir |
Environment to evaluate the glue expressions in. |
1 2 3 4 5 | cli_alert("Cannot lock package library.")
cli_alert_success("Package {.pkg cli} installed successfully.")
cli_alert_danger("Could not download {.pkg cli}.")
cli_alert_warning("Internet seems to be unreacheable.")
cli_alert_info("Downloaded 1.45MiB of data")
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.