mirror of
https://github.com/DavidAnson/markdownlint.git
synced 2026-01-22 15:06:13 +01:00
26 lines
1 KiB
Markdown
26 lines
1 KiB
Markdown
This rule is triggered on any heading that has one of the specified normal or
|
|
full-width punctuation characters as the last character in the line:
|
|
|
|
```markdown
|
|
# This is a heading.
|
|
```
|
|
|
|
To fix this, remove the trailing punctuation:
|
|
|
|
```markdown
|
|
# This is a heading
|
|
```
|
|
|
|
Note: The `punctuation` parameter can be used to specify what characters count
|
|
as punctuation at the end of a heading. For example, you can change it to
|
|
`".,;:"` to allow headings that end with an exclamation point. `?` is
|
|
allowed by default because of how common it is in headings of FAQ-style documents.
|
|
Setting the `punctuation` parameter to `""` allows all characters - and is
|
|
equivalent to disabling the rule.
|
|
|
|
Note: The trailing semicolon of
|
|
[HTML entity references](https://en.wikipedia.org/wiki/List_of_XML_and_HTML_character_entity_references)
|
|
like `©`, `©`, and `©` is ignored by this rule.
|
|
|
|
Rationale: Headings are not meant to be full sentences. More information:
|
|
<https://cirosantilli.com/markdown-style-guide#punctuation-at-the-end-of-headers>
|