fuse_site: Fuse R Markdown documents individually under a directory

View source: R/site.R

fuse_siteR Documentation

Fuse R Markdown documents individually under a directory

Description

Run fuse() on R Markdown documents individually to generate a website.

Usage

fuse_site(input = ".")

Arguments

input

The root directory of the site, or a vector of input file paths.

Details

If a directory contains a config file ⁠_litedown.yml⁠, which has a YAML field site, the directory will be recognized as a site root directory. The YAML field output will be applied to all R Markdown files (an individual R Markdown file can provide its own output field in YAML to override the global config). For example:

---
site:
  rebuild: "outdated"
  pattern: "[.]R?md$"
output:
  litedown::html_format:
    meta:
      css: ["@default"]
      include_before: "[Home](/) [About](/about.html)"
      include_after: "© 2024 | [Edit]($input$)"
---

The option rebuild determines whether to rebuild .Rmd files. Possible values are:

  • newfile: Build an input file if it does not have a .html output file.

  • outdated: Rebuild an input file if the modification time of its .html output file is newer than the input.

Value

Output file paths (invisibly).


litedown documentation built on Oct. 17, 2024, 1:06 a.m.