From 00987215b7572def2f5cd73a623efc38f4f30ab7 Mon Sep 17 00:00:00 2001 From: Yihui Xie Date: Thu, 5 Nov 2020 08:15:54 -0600 Subject: [PATCH] use the exported xfun::is_rel_path() --- DESCRIPTION | 2 +- R/html.R | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index e0ad052e9..cfc976b4d 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,7 +1,7 @@ Package: bookdown Type: Package Title: Authoring Books and Technical Documents with R Markdown -Version: 0.21.3 +Version: 0.21.4 Authors@R: c( person("Yihui", "Xie", role = c("aut", "cre"), email = "xie@yihui.name", comment = c(ORCID = "0000-0003-0645-5666")), person("JJ", "Allaire", role = "ctb"), diff --git a/R/html.R b/R/html.R index 9032ad826..5874c9da5 100644 --- a/R/html.R +++ b/R/html.R @@ -1032,7 +1032,7 @@ move_files_html = function(output, lib_dir) { f = gsub('[?#].+$', '', f) # strip the #/? part in links, e.g. a.html#foo f = gsub('^[.]/', '', f) # strip the initial ./, e.g. ./foo.png -> foo.png f = f[f != ''] - f = f[!knitr:::is_abs_path(f)] + f = f[xfun::is_rel_path(f)] if (getOption('bookdown.js.debug', FALSE)) f = c(f, js_min_sources(f)) # add leaflet images if any used f = c(f, grep('png$', list.files(