Pushes a code comment chunk for global chunks
chunks_push_comment.Rd
Usage
chunks_push_comment(comment, chunks = get_chunks_object())
Arguments
- comment
(codecharacter) Comment to be inserted into the Show-R code.
- chunks
optional, (
chunks
) object. If not provided then automaticchunks
object detection is run via get_chunks_object
Examples
all_chunks <- chunks_new()
chunks_push_comment("this is a comment", chunks = all_chunks)
chunks_get_rcode(chunks = all_chunks) == "# this is a comment"
#> chunk_1
#> TRUE