mirror of
https://github.com/DavidAnson/markdownlint.git
synced 2026-04-25 01:05:55 +03:00
[GH-ISSUE #514] Possible to disable line length for normal lines but enforce for headers/code blocks? #422
Labels
No labels
bug
enhancement
enhancement
enhancement
fixed in next
fixed in next
fixed in next
new rule
new rule
new rule
pull-request
question
refactoring
refactoring
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/markdownlint#422
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @wgehring-ml on GitHub (Mar 31, 2022).
Original GitHub issue: https://github.com/DavidAnson/markdownlint/issues/514
Title says it all, really. I see ways to disable enforcing
MD013/line_lengthon headers/headings, code blocks, and tables but no way to enforce on headers/code blocks and ignore elsewhere.Is there a way to do this already, and if not could it be added?
@DavidAnson commented on GitHub (Mar 31, 2022):
See the docs: https://github.com/DavidAnson/markdownlint/blob/main/doc/Rules.md#md013
heading_line_length lets you set the length for headings
headings let's you disable for headings
Similar for code and tables (though you can't control table length, just disable).
@wgehring-ml commented on GitHub (Apr 1, 2022):
Yes, I saw that, but there's no way to disable the check for normal lines and enforce it on others. As far as I can tell, the closest I can get to actually disabling it is to guess how long my general content lines may become and set the
line_lengthproperty inside ofMD013to be larger than that.If that's the answer, that's all well and good but since the rule is using Regex to enforce line length I worry about increasing that value to the point where the rule slows down or freezes.
@DavidAnson commented on GitHub (Apr 1, 2022):
I've never heard of the RegExp being a problem here. As long as your lines are reasonable lengths, it should bail out when they end anyway.
@wgehring-ml commented on GitHub (Apr 1, 2022):
Alright, thanks for your help.