tests/testthat/roxygen-examples-identify/5-multiple-function-examples-last-proper-run.R

#' The tidyverse style
#'
#' Style code according to the tidyverse style guide.
#' @family style_guides
#' @examples
#' style_text("call( 1)", style = tidyverse_style, scope = "spaces")
#' style_text("call( 1)", transformers = tidyverse_style(strict = TRUE))
#' style_text(c("ab <- 3", "a  <-3"), strict = FALSE) # keeps alignment of "<-"
#' style_text(c("ab <- 3", "a  <-3"), strict = TRUE) # drops alignment of "<-"
a <- call

#' Prettify R source code
#'
#' Performs various substitutions in all `.R` files in a package
#' (code and tests).
#' Carefully examine the results after running this function!
#' @examples style_pkg(style = tidyverse_style, strict = TRUE)
a <- 2
r-lib/styler documentation built on April 10, 2024, 4 a.m.