Skip to content
This repository has been archived by the owner on Apr 3, 2024. It is now read-only.

Handle CommonMark-incompliant multiline HTML comments without clobbering comments in code blocks #42

Closed
zeke opened this issue Apr 21, 2015 · 2 comments
Labels

Comments

@zeke
Copy link
Contributor

zeke commented Apr 21, 2015

markdown-it freaks out on malformed/spec-incompliant multiline HTML comments:

A while back I added some code to marky-markdown that removed HTML comments from strings before passing them to the markdown-it parser. This solved the problem for the above-mentioned READMEs, but introduced new problems in other places. Some READMEs contain HTML comments within code blocks, and those should not be removed. For example:

There are at least two possible solutions to this:

  1. Figure out a way to remove HTML comments that aren't within a code block.
  2. Write a custom html_block function for markdown-it
@zeke zeke added the bug label Apr 21, 2015
@puzrin
Copy link

puzrin commented Jul 19, 2015

https://github.com/markdown-it/markdown-it/blob/master/CHANGELOG.md#440--2015-07-18

Should be fixed in markdown-it 4.4.0, you need to upgrade dependency.

@zeke
Copy link
Contributor Author

zeke commented Sep 8, 2015

👏 Thank you @soldair and @puzrin

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants