Automattic / Automattic/harper
Replace `U+0022` with `U\+201(C|D)`.
- Dominant language
- Rust
- Stars
- 15.4k
- Forks
- 627
- Avg merge
- 1d 15h
- Merged PRs (30d)
- 106
Description
#### Examples
As [`issues/3273`](https://github.com/Automattic/harper/issues/3273#issue-4357533454) demonstrates, we currently replace some characters with their semantic alternatives:
https://github.com/Automattic/harper/blob/860753b9fbea25b6b621af1ac6db3f43dd97dfa1/harper-core/src/linting/use_ellipsis_character.rs#L17-L25
However, [unlike LanguageTool](https://github.com/languagetool-org/languagetool/blob/8a1a2455ca32b4ece4e70d79286e7d9731e6440b/languagetool-core/src/main/java/org/languagetool/rules/AbstractStatisticStyleRule.java#L45-L46) (and Discourse), Harper does not replace quotation marks:
Keyboard-Accessible (`U+0022`) | Ideal
-|-
`"…` / Quotation Commencement | `“` / `U+201C`
`…"` / Quotation Cessation | `”` / `U+201D`
#### Additional Context
This may affect [`issues/1`](https://github.com/Automattic/harper/issues/1#issue-2088566166).
Contributor guide
Research direction
Start with harper-core/src/linting/use_ellipsis_character.rs, especially the linked lines, to understand how semantic character replacements are implemented. Compare the desired U+0022 behavior with the LanguageTool reference and verify that opening quotes become U+201C and closing quotes become U+201D without disrupting existing replacements.
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
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 68/100