Skip to content

Access document YAML metadata in output format function #673

@aoles

Description

@aoles

Is it possible to access YAML metadata of the current R Markdown document inside an output format function? I tried to use rmarkdown::metadata for this purpose but the returned list is empty at the time the format function is run.

The motivation for this is, for example, to adjust "width" in opts_knit according to fontsize specified in the YAML header.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions