Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

start_comments_with_space

Start comments with a space


Description

Forces comments to start with a space, that is, after the regular expression #+['\\*], at least one space must follow if the comment is non-empty, i.e there is not just spaces within the comment. Multiple spaces may be legit for indention in some situations.

Usage

start_comments_with_space(pd, force_one = FALSE)

Arguments

pd

A parse table.

force_one

Whether or not to force one space or allow multiple spaces.

Exceptions

Spaces won't be added to comments when they are:

  • shebangs

  • code chunk headers

  • xaringan markers


styler

Non-Invasive Pretty Printing of R Code

v1.4.1
MIT + file LICENSE
Authors
Kirill Müller [aut], Lorenz Walthert [cre, aut]
Initial release

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.