-
Couldn't load subscription status.
- Fork 195
Description
No matter where lint messages are printed (e.g. GitHub annotations, RStudio markers, Markdown in GitHub issues, etc.), currently, there is no straightforward way to print them with a certain width. This means that the user always needs to scroll horizontally to see many of the lint messages.
options(width = 50)
library(lintr)
lint(
text = "x <- c();",
linters = unnecessary_concatenation_linter()
)
#> <text>:1:6: style: [unnecessary_concatenation_linter] Unneeded concatenation without arguments. Replace the "c" call by NULL or, whenever possible, vector() seeded with the correct type and/or length.
#> x <- c();
#> ^~~Created on 2023-01-03 with reprex v2.0.2
A typical project that starts using linters might throw hundreds of messages, and that's a lot of scrolling. This might be mildly annoying for an able-bodied individual like me, but must be extremely challenging and disappointing for people with mobility impairment. Almost every single lint asks them to scroll to see the full lint message.
We should anticipate this and provide a way out.