| govReactable-shiny | R Documentation |
Shiny bindings for govReactable Output and render functions for using govReactable within shiny apps
govReactableOutput(
output_table_name,
caption,
caption_size = "l",
heading_level = "h2"
)
renderGovReactable(expr, env = parent.frame(), quoted = FALSE)
output_table_name |
Output variable to read from |
caption |
Adds a caption to the table as a header |
caption_size |
Adjust the size of caption Options are s, m, l, xl, with l as the default |
heading_level |
The HTML heading level for the caption (e.g., "h2", "h3", "h4", "h5"). Default is "h2" |
expr |
An expression that generates a |
env |
The environment in which to evaluate |
quoted |
Is |
govReactableOutput() returns a reactable output element
that can be included in a Shiny UI
renderGovReactable() returns a reactable render function that
can be assigned to a Shiny output slot
Other Govstyle tables tabs and accordions:
accordion(),
govReactable(),
govTable(),
govTabs()
ui <- shiny::fluidPage(
govReactableOutput(
"table",
caption = "Example table"
)
)
server <- function(input, output, session) {
output$table <- renderGovReactable({
govReactable(iris)
})
}
if (interactive()) shinyApp(ui, server)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.