Description Usage Arguments Details Value Examples
View source: R/modularTabPanels.R
Maps over modules, converting Shiny UI code into tabPanel()
objects.
1 | modularTabPanels(module.dir, module.file, numbered = FALSE)
|
module.dir |
Path to directory that contains modules (child directories) |
module.file |
Name of file found within module directories that contains UI code |
numbered |
If |
This function can be used on its own if desired, but modularUI() can be used to pass the tabPanels to a UI function more succinctly.
A list of Shiny tabPanel()
objects
1 2 3 4 5 6 7 8 9 10 11 | # Create a list of tabPanels from ui.R files
## Not run:
server <- function(input, output, session) {
tabPanels <- modularTabPanels(
module.dir = file.path('.', 'modules'),
module.file = 'ui.R',
numbered = TRUE
)
}
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.