Closed elgabbas closed 1 month ago
I would like to disable styler of adding a new line before the closing bracket of a long function call
styler
Here is an example
example <- 'c( "Mazda RX4", "Mazda RX4 Wag", "Datsun 710", "Hornet 4 Drive", "Hornet Sportabout", "Valiant", "Duster 360", "Merc 240D", "Merc 230", "Merc 280")' styler::style_text(example)
The output
c( "Mazda RX4", "Mazda RX4 Wag", "Datsun 710", "Hornet 4 Drive", "Hornet Sportabout", "Valiant", "Duster 360", "Merc 240D", "Merc 230", "Merc 280" )
Is it possible to get the following instead?
c( "Mazda RX4", "Mazda RX4 Wag", "Datsun 710", "Hornet 4 Drive", "Hornet Sportabout", "Valiant", "Duster 360", "Merc 240D", "Merc 230", "Merc 280")
Thanks
Not with minimal effort, as this is not in line with the tidyverse style guide. You would have to modify the transformer rules that create a line break as described per the vignettes in this package.
I would like to disable
styler
of adding a new line before the closing bracket of a long function callHere is an example
The output
Is it possible to get the following instead?
Thanks