Description Usage Arguments Value See Also Examples
Creates a DT DataTable based on the settings specified in the context.
1 | createDT(.context)
|
.context |
List. The shinyXT context. |
A DT DataTable
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 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 | onetable_df <- data.frame(
a0_num = c(1, 2, 3, 4)
)
onetable_xt <- list(
.default = list(
col_name = NA_character_,
class = NA_character_,
ui_name = NA_character_,
hover = NULL,
widget = NULL,
format = NULL,
column_width = 3,
width = "100%",
visible = TRUE,
enabled = TRUE,
validate = NULL
),
.options = list(),
a0_num = list(
col_name = "a0_num",
class = "numeric",
ui_name = "Col A0",
hover = "Numeric, no decimals",
widget = "numericInput",
format = "",
validate = NULL
)
)
context_default <- list(
tbl_name = "onetable",
tbl_lst = list(
onetable = onetable_df
),
filter_lst = NULL,
mode = "dt",
xt_lst = list(
onetable = onetable_xt
)
)
xt <- shinyXT::getConfigMode(context_default)
dt <- shinyXT::createDT(context_default)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.