[GH-ISSUE #223] Additional style check for fenced code block: backticks vs quotes #192

Closed
opened 2026-03-03 01:24:33 +03:00 by kerem · 1 comment
Owner

Originally created by @RedX2501 on GitHub (Sep 27, 2019).
Original GitHub issue: https://github.com/DavidAnson/markdownlint/issues/223

Currently rule MD046 only checks for indented vs fenced but it seems that some dialects of markdown allow fencing to use ~~~ over ```.

It would be nice if a new rule was added (or MD046 expanded) where you could define whether fenced code blocks uses tildes, backticks or it should be consistent. Pretty much how lists work.

See https://sourceforge.net/p/tilde/wiki/markdown_syntax/ and https://www.markdownguide.org/extended-syntax/#fenced-code-blocks for two examples where ~ is allowed.

Originally created by @RedX2501 on GitHub (Sep 27, 2019). Original GitHub issue: https://github.com/DavidAnson/markdownlint/issues/223 Currently rule MD046 only checks for indented vs fenced but it seems that some dialects of markdown allow fencing to use `~~~` over ` ``` `. It would be nice if a new rule was added (or MD046 expanded) where you could define whether fenced code blocks uses tildes, backticks or it should be consistent. Pretty much how lists work. See https://sourceforge.net/p/tilde/wiki/markdown_syntax/ and https://www.markdownguide.org/extended-syntax/#fenced-code-blocks for two examples where ~ is allowed.
kerem 2026-03-03 01:24:33 +03:00
Author
Owner

@DavidAnson commented on GitHub (Sep 27, 2019):

Agreed. https://spec.commonmark.org/0.29/#fenced-code-blocks

<!-- gh-comment-id:536000452 --> @DavidAnson commented on GitHub (Sep 27, 2019): Agreed. https://spec.commonmark.org/0.29/#fenced-code-blocks
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/markdownlint#192
No description provided.