Add DT datatable
add_DT.RdAdd DT datatable
Examples
if (FALSE) { # \dontrun{
# Option 1: Pass a styled DT object
my_dt <- DT::datatable(
mtcars,
options = list(pageLength = 10),
filter = 'top',
rownames = FALSE
)
content <- create_content() %>%
add_DT(my_dt)
# Option 2: Pass a data frame with options
content <- create_content() %>%
add_DT(mtcars, options = list(pageLength = 5, scrollX = TRUE))
} # }