Aliases |
---|
md036 |
no-emphasis-as-heading |
no-emphasis-as-header |
Emphasis possibly used instead of a heading element.
To people that are new to Markdown, there may be an old habit of using various forms of emphasis to create a heading, instead of using Markdown's Atx Heading element or SetExt Heading element. The heading elements are present to allow a higher semantic meaning to be associated with the text, rather than the more simplistic emphasis meaning associated with text that is emphasized.
This rule triggers when a single line of text is present in a Paragraph element, the entirety of the text is within an Emphasis element, and that text does not end with any of the configured punctuation characters.
**My document**
Lorem ipsum dolor sit amet...
_Another section_
Consectetur adipiscing elit, sed do eiusmod.
This rule does not trigger when all of the above constraints have not been met:
**My
document**
Lorem ipsum dolor sit amet...
_Almost a section_ heading
Consectetur adipiscing elit, sed do eiusmod.
*But this is not a heading!*
Consectetur adipiscing elit, sed do eiusmod.
Prefixes |
---|
plugins.md036. |
plugins.no-emphasis-as-heading. |
plugins.no-emphasis-as-header. |
Value Name | Type | Default | Description |
---|---|---|---|
enabled |
boolean |
False |
Whether the plugin rule is enabled by default. |
punctuation |
string |
".,;:!?。,;:?" |
Punctuation characters that are considered sentence ending characters. |
This rule is largely inspired by the MarkdownLint rule MD036. and this article.
The original rule did not work inside of Block Quote elements or List elements.