Open RokeJulianLockhart opened 1 year ago
This is something people depend on to break adjacent lists (with CM you can now also do that by using a different bullet, as in . or ), but not all other markdown flavors support that)
The current user expectation is that block-level HTML content participates in the container hierarchy like any other block element. For example, an unindented HTML table is expected to be placed in the document root container, interrupting any preceding list just as the unindented HTML comment above does.
The OP's requested behavior would require special-casing HTML comments.
Not to mention upgrading HTML's role in Markdown, which I don't think is a good idea and goes against both the original and current intent.
To reproduce
(scroll) produces
in https://github.com/microsoft/vscode/issues/186232#issue-1775755236, which is obviously wrong.
Alternatives
I can't use
(per https://stackoverflow.com/a/4829998/9731176) since https://github.com/microsoft/vscode/ doesn't render them using whatever https://github.com/commonmark/commonmark-spec/ -compliant engine it uses.
Origin
Due to https://talk.commonmark.org/t/html-comment-tags-break-markdown-list-indentation/4459/2?u=rokejulianlockhart, reported here.