2

I would like to include a rendered HTML project, created with Quarto, in a shinyApp in order to create a documentation page of the app.

So far, I was able to use successfully use includeMarkdown, to include simple markdown (without plots though), and also includeHTML(knitr::knit2html("doc.Rmd", fragment.only = TRUE)) did render the text, equations, highlight code, and plot generated by doc.Rmd file. However I am loosing some of the cool feature from rendering with quarto to html, e.g. a leftsided toc, better control of crossreferences, and other cool yaml configurations. Is there a way to include a basic, but complete, quarto rendered html project in a tabPanel() section of the shinyApp? Perhaps something like tags$iframe()? Another workaround, even though not ideal, is put actiolink to a html project, which lives somewhere within the app folder.

pimakes
  • 21
  • 1
  • Warm welcome to SO. Please read https://stackoverflow.com/help/how-to-ask and https://stackoverflow.com/help/minimal-reproducible-example. Then update your question with code to show us what you have tried so far. – buhtz Feb 23 '23 at 08:29
  • 1
    I'd recommend using an iframe as done [here](https://stackoverflow.com/questions/64460159/display-pdf-file-which-isnt-stored-on-www-folder-inside-r-shiny-app/64462560#64462560). This example is using a pdf file but it worksin the same manner for html. – ismirsehregal Feb 23 '23 at 09:06
  • 1
    @buhtz sorry for that. It's the first time I use stackoverflow. – pimakes Feb 23 '23 at 13:12
  • 1
    @ismirsehregal it worked flawlessly thanks! the framed page it's not the neatest thing in the world, but it works just like I wanted it to. Thank you very much! – pimakes Feb 23 '23 at 13:16
  • 1
    @pimakes you can style the frame according to your needs. Please see my related answer [here](https://stackoverflow.com/questions/71219778/how-to-programmatically-filter-contents-of-a-second-shiny-app-displayed-via-ifra/71325272#71325272) and check the `style` parameter of the iframe tag. – ismirsehregal Feb 23 '23 at 14:07
  • 1
    @ismirsehregal wow!! I can't believe this is working perfectly. Huge thanks. – pimakes Feb 23 '23 at 15:08

0 Answers0