tidyverse / style

The tidyverse style guide for R code
https://style.tidyverse.org
Other
293 stars 100 forks source link

Closing brace for double-indented function declaration #202

Closed krlmlr closed 1 year ago

krlmlr commented 1 year ago

styler and this style guide

x <- function(
    a,
    b) {
}

codegrip

x <- function(
    a,
    b
) {
}

Problem

This inconsistency makes it difficult to use codegrip with styler. Can we get a consensus here? The desired outcome would be to allow both forms, or to even switch to recommending the second form. This is fairly easy to change in styler, I can help here.

MichaelChirico commented 1 year ago

See https://github.com/tidyverse/style/issues/173#issuecomment-904073980 as well as discussion on the implementing PR.

this was already proposed and rejected IIUC.

krlmlr commented 1 year ago

Thanks for the heads-up.