docx_simple: Convert to UNHCR branded Word document

View source: R/docx_simple.R

docx_simpleR Documentation

Convert to UNHCR branded Word document

Description

Format for converting from R Markdown to an UNHCR branded Word simple document

Usage

docx_simple(...)

Arguments

...

extra parameters to pass to officedown::rdocx_document

Value

An R Markdown output format.

Examples

## Not run: 
# Requires pandoc

# Create an R Markdown example file
rmd_content <- "---
 title: 'Example UNHCR Word Document'
 output: unhcrdown::docx_simple
 ---

 ## Introduction

 This is an example of a UNHCR-branded Word document created using `unhcrdown::docx_simple`.
 "

# Write the R Markdown content to a file
example_file <- tempfile(fileext = ".Rmd")
writeLines(rmd_content, example_file)

# Render the R Markdown file
rmarkdown::render(example_file,
  output_format = unhcrdown::docx_simple(),
  output_dir = tempdir()
)

## End(Not run)

unhcrdown documentation built on April 3, 2025, 10:49 p.m.