mirror of
https://github.com/rstudio/shiny.git
synced 2026-04-07 03:00:20 -04:00
basically library(pkg) = if (!require(pkg)) stop()
This commit is contained in:
@@ -108,8 +108,7 @@ includeText <- function(path) {
|
||||
#' @rdname include
|
||||
#' @export
|
||||
includeMarkdown <- function(path) {
|
||||
if (!require(markdown))
|
||||
stop("markdown package is not installed")
|
||||
library(markdown)
|
||||
|
||||
dependsOnFile(path)
|
||||
html <- markdown::markdownToHTML(path, fragment.only=TRUE)
|
||||
|
||||
Reference in New Issue
Block a user