Running Shiny app with global file that has a different name

171 views Asked by At

I have one folder with 2 Shiny apps inside - they share ui.R and server.R but their global.R files differ. How to run Shiny app with global2.R file instead of global.R? I was trying

shiny::shinyApp(
  ui = source("ui.R")$value, 
  server = source("server.R")$value, 
  onStart = source("global2.R")
)

but it doesn't work. Not sure if relevant but I'm publishing the app on RStudo Connect.

0

There are 0 answers