Skip to content

Conversation

@eksperimental
Copy link
Contributor

@eksperimental eksperimental commented Nov 27, 2025

Rule MD024: We allow duplication for headings with different parents, but not within the same parent.

@eksperimental eksperimental changed the title Enforce Markdown MD024: Multiple headings with the same content Enforce Markdown: Multiple headings with the same content Nov 27, 2025
We allow duplication for headings with different parents in rule MD024.
@eksperimental eksperimental force-pushed the chore/markdown-tighten-up4 branch from ceb132a to e3af8c5 Compare November 28, 2025 00:09
Copy link
Member

@whatyouhide whatyouhide left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice, didn't know about this option.

@sabiwara
Copy link
Contributor

Couldn't this cause issues in URL anchors though?

@josevalim
Copy link
Member

@sabiwara ExDoc at least deals with duplicate headers (and I'd expect most markdown renderers to deal with it too).

@josevalim josevalim merged commit 66165e6 into elixir-lang:main Nov 28, 2025
14 checks passed
@josevalim
Copy link
Member

💚 💙 💜 💛 ❤️

@eksperimental
Copy link
Contributor Author

Couldn't this cause issues in URL anchors though?

Note that what this rule is doing is avoiding the duplicated headers within a document; in particular within the same section.

@eksperimental eksperimental deleted the chore/markdown-tighten-up4 branch November 28, 2025 12:32
@sabiwara
Copy link
Contributor

Note that what this rule is doing is avoiding the duplicated headers within a document; in particular within the same section.

Yes but the rationale for the rule seemed to be about anchors, hence my question.

Rationale: Some Markdown parsers generate anchors for headings based on the heading name; headings with the same content can cause problems with that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

4 participants