check_header: Check markdown header

View source: R/check-rmd.R

check_headerR Documentation

Check markdown header

Description

Checks if a markdown header with a certain level exists. If not, generates a feedback message. If yes, zooms in on the entire header section.

Usage

check_header(state, level, index = 1, not_found_msg = NULL,
  append = TRUE)

Arguments

state

the state to start from.

level

the level of the header to check

index

which h<level> header to check

not_found_msg

If specified, this overrides the automatically generated message in case not enough headers of the specified level were found.

append

Whether or not to append the feedback to feedback built in previous states

Value

A state that zooms in on the section under the header until the next same-level header.


Data-Camp/testwhat documentation built on June 24, 2022, 9:59 p.m.