transformers_drop: Remove transformers that are not needed

View source: R/transform-files.R

transformers_dropR Documentation

Remove transformers that are not needed

Description

The goal is to speed up styling by removing all rules that are only applicable in contexts that don't occur often, e.g. for most code, we don't expect ";" to be in it, so we don't need to apply resolve_semicolon() on every nest.

Usage

transformers_drop(text, transformers)

Arguments

text

Text to parse. Can also be the column text of the output of compute_parse_data_nested(), where each element is a token (instead of a line).

transformers

the transformers.

See Also

specify_transformers_drop


styler documentation built on Aug. 29, 2023, 5:10 p.m.