Procházet zdrojové kódy

Use writeLines() instead of cat()

tags/v0.1.1
Garrick Aden-Buie před 8 roky
rodič
revize
7a9b5b79b0
2 změnil soubory, kde provedl 2 přidání a 2 odebrání
  1. +1
    -1
      R/write_theme.R
  2. +1
    -1
      inst/scripts/write_xaringan_theme_body.R

+ 1
- 1
R/write_theme.R Zobrazit soubor

@@ -139,7 +139,7 @@ write_xaringan_theme <- function(
template <- readLines(tf, warn = FALSE)
template <- paste(template, collapse = "\n")
x <- glue::glue(template, .open = "{{", .close = "}}")
cat(x, file = outfile)
writeLines(x, con = outfile)
if (!is.null(extra_css)) write_extra_css(extra_css, outfile)
outfile
}

+ 1
- 1
inst/scripts/write_xaringan_theme_body.R Zobrazit soubor

@@ -34,6 +34,6 @@ tf <- system.file("resources", "template.css", package = "xaringanthemer")
template <- readLines(tf, warn = FALSE)
template <- paste(template, collapse = "\n")
x <- glue::glue(template, .open = "{{", .close = "}}")
cat(x, file = outfile)
writeLines(x, con = outfile)
if (!is.null(extra_css)) write_extra_css(extra_css, outfile)
outfile

Načítá se…
Zrušit
Uložit