Skip to contents

add quoted attribute for yaml package

Usage

yaml_quoted(x)

Arguments

x

character

Examples

yaml <- list(
  author = teal.reporter:::yaml_quoted("NEST"),
  title = teal.reporter:::yaml_quoted("Report"),
  date = teal.reporter:::yaml_quoted("07/04/2019"),
  output = list(pdf_document = list(keep_tex = TRUE))
)
yaml::as.yaml(yaml)
#> [1] "author: \"NEST\"\ntitle: \"Report\"\ndate: \"07/04/2019\"\noutput:\n  pdf_document:\n    keep_tex: yes\n"