Build a workflow in R shiny

Hi all,

Hope all are safe there :slight_smile:

In the below simple application (rather my question should hold for all applications as well), is there a way to build workflow, so that we can get to know about the application well. For example

In this app,
In terms of UI.R

  1. There is 1 actionbutton (So can we list the number of action buttons in the app, along with there ID's)
  2. There is 1 dataTableoutput (So can we list the number of dataTableoutput in the app, along with there ID's)

So in general, can we list the number of inputs and there type(actionbutton, radiobutton etc)

Interms of Server.R
3) Can we show that dataTableOutput("Test") is dependent on actionButton("plot"). I mean can we extract a list of outputs that is dependent on observerEvents?
So basically, just by running the small chunk of code, the user should know that this output(test) is dependent on observeEvent(plot).?

library(shiny)
library(dplyr)
library(shinycssloaders)
library(DT)

ui <- fluidPage(
    
    actionButton("plot","plot"),
    dataTableOutput("Test")
)



server <- function(input, output, session) {
    
    observeEvent(input$plot, {
        output$Test <- DT::renderDT(DT::datatable(head(iris),
                                                  rownames = FALSE, options = list(dom = 't', 
                                                                                   ordering=FALSE)))
        
    })
}
shinyApp(ui = ui, server = server)

This topic was automatically closed 54 days after the last reply. New replies are no longer allowed.