Markdown parser, done right. 100% CommonMark support, extensions, syntax plugins & high speed https://markdown-it.github.io/
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

79 lines
901 B

Regression tests for link backtracking optimizations:
.
[[some unrelated text [link]
[link]: foo
.
<p>[[some unrelated text <a href="foo">link</a></p>
.
.
[[some unrelated text [[link]]
[[link]]: foo
.
<p>[[some unrelated text <a href="foo">[link]</a></p>
.
This is not a valid emphasis, because \n considered a whitespace:
.
**test
**
**
test**
**
test
**
.
<p>**test
**</p>
<p>**
test**</p>
<p>**
test
**</p>
.
Link label has priority over emphasis (not covered by commonmark tests):
.
[**link]()**
**[link**]()
.
<p><a href="">**link</a>**</p>
<p>**<a href="">link**</a></p>
.
Issue #55:
.
![test]
![test](foo bar)
.
<p>![test]</p>
<p>![test](foo bar)</p>
.
Should unescape only needed things in link destinations/titles:
.
[test](<\f\o\o\>\\>)
.
<p><a href="%5Cf%5Co%5Co%3E%5C">test</a></p>
.
.
[test](foo "\\\"\b\a\r")
.
<p><a href="foo" title="\&quot;\b\a\r">test</a></p>
.