mirror of
https://github.com/DavidAnson/markdownlint.git
synced 2026-04-25 09:16:02 +03:00
[GH-ISSUE #136] Rule MD024 should be refined [to allow heading duplication for non-siblings] #1963
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#1963
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 @bfzhao on GitHub (Jul 17, 2018).
Original GitHub issue: https://github.com/DavidAnson/markdownlint/issues/136
It is reasonable to have rule MD024 to report any title conflict, but it makes sense only when those titles have the same parent title. Below case is very common and should not be reported as an issue:
@DavidAnson commented on GitHub (Jul 17, 2018):
Although this conflicts with the rationale given in the rule description (https://github.com/DavidAnson/markdownlint/blob/master/doc/Rules.md#md024---multiple-headings-with-the-same-content), it seems reasonable as an option.
@DavidAnson commented on GitHub (Jul 17, 2018):
Here’s a corresponding issue/commit from the Ruby implementation:
https://github.com/markdownlint/markdownlint/issues/175
I prefer a parameter name like
only_siblingsand will probably support both for compatibility.@Coding-Rod commented on GitHub (Jul 27, 2023):
Add this to your setting.json if using vscode:
@lveillard commented on GitHub (Nov 13, 2023):
I know it can be ignored, but this rule actually makes sense within the same scope. I think that this rule should be:
a) either enhanced to check only within scope
b) defaulted to false. And a new rule to check same-level conflicts only could be added