Skip to content

Instantly share code, notes, and snippets.

@vankesteren
Created November 1, 2018 10:42
Show Gist options
  • Select an option

  • Save vankesteren/b981f0686b17a977f4d091b7623c5d3a to your computer and use it in GitHub Desktop.

Select an option

Save vankesteren/b981f0686b17a977f4d091b7623c5d3a to your computer and use it in GitHub Desktop.
View local html files in viewer of Rstudio
view_html <- function(path, height = "maximize") {
tf <- tempfile(fileext = ".html")
file.copy(path, tf)
rstudioapi::viewer(tf, height = height)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment