Automattic / Automattic/harper
We should flag missing space outside parentheses and extraneous space inside parentheses.
- Dominant language
- Rust
- Stars
- 15.4k
- Forks
- 627
- Avg merge
- 1d 12h
- Merged PRs (30d)
- 106
Description
This is extremely common, both by people writing in a hurry and by East Asians whose CJK fonts have double-width parentheses that include space on the outside.
It's possibly also common among coders who might bring some of their code formatting across to their prose either by accident or unaware that spaces are needed. I haven't really noticed this in practice yet though.
The fix can be heavily based on the `CommaFixes` linter.
Contributor guide
Research direction
Start by locating the CommaFixes linter and its associated tests, since the issue identifies it as the model for this change. Check how it detects spacing patterns and add coverage for missing space outside parentheses and extraneous space inside them; done means both cases are flagged without altering unrelated punctuation checks.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- tooling
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 64/100