Act fast, special offers end soon! Up to $294 is savings when you get Premium today.
Get offer codes

Html_preserve appears around images

I’m having trouble with the function below. I get a
<!--html_preserve--> appearing around my image. This only happens in the app and not in the html file created.

My Code:
In global.R

rmd2UI <- function(file_path) {

  # knits the file quietly and places it in the Shiny directory
  knit_file <- knitr::knit(input = file_path, quiet = TRUE)

  # Takes the knit file and converts it into 
  rendered_rmd <- HTML(markdown::markdownToHTML(knit_file, fragment.only = TRUE))


I have the following in splash.rmd

img(src = "picture.png")


output$splash_page <- renderUI({

and in ui.R