Description Usage Arguments Examples
Reveal a message box and display a message
1 | show_error_box(inputId, error)
|
inputId |
ID of error to update |
error |
message to display |
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 | if (interactive()) {
library(shiny)
ui <- tagList(
iceComponents::use_iceComponents(),
iceComponents::container(
iceComponents::page(
tags$h2("My App"),
iceComponents::error_box(
inputId = "shiny-server-error"
),
tags$button(
id = "show",
class = "shiny-bound-input action-button",
"Do Something"
)
)
)
)
server <- function() {
observeEvent(input$show, {
iceComponents::show_error_box(
inputId = "shiny-server-error",
error = "Internal Server Error (500)"
)
})
}
shinyApp(ui, server)
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.