5

I have been searching for this problem for a few hours and I cannot seem to find the right solution. I would appreciate any help regarding how to fix this.

I have a flexdashboard in my RStudio Server, and in it, I have one gvisGeoChart that I have wrapped in a dynamic UI. Like below:

output: 
  flexdashboard::flex_dashboard:
  html_document: default
  orientation: rows
  vertical_layout: scroll
  theme: bootstrap

runtime: shiny

library(shiny)
library(flexdashboard)
library(googleVis)


# #create a ui interaction:
uiOutput("dynamic")

#render the ui:
output$dynamic <- renderUI({
   htmlOutput("myTable")
 })

#plot the chart
output$myTable <- renderGvis({gvisGeoChart(buyer_eur, locationvar = 
"Buyers", colorvar = "Sum of Invoices",
         options = list("regions",
                        height = "auto",
                        width = "auto")})

My dashboard renders beautifully when I run it inside my RStudio. It shows the interactive plot. However, I do not see any html output from this .Rmd file saved in the same directory (which knitting usually does). Instead I see the file is saved in a /tmp folder, like this:

Output created: /tmp/RtmpYG0i95/file320c5f4901a.html

I go and get this file, but when I open it on my local machine, I see a blank page only.

Can someone please tell me how I can produce an html file out of this dashboard that can be used?

Phil
  • 7,287
  • 3
  • 36
  • 66
Nazaniiin
  • 51
  • 4

1 Answers1

0

A bit late to the party but as far as I know, any document with runtime: shiny will require some form of shiny back-end to be evaluated in, hence no usable html will be generated that can be viewed outside of the context of a Shiny server or publication tools like Rstudio connect or shinyapps.io. In Rstudio (server) you should also observe that the "knit" button is replaced by a "Run Document" button, which makes it possible to run the document locally by creating a shiny server to evaluate it in (see the documentation of rmarkdown::run().

FM Kerckhof
  • 1,270
  • 1
  • 14
  • 31