Fix MD011/no-reversed-links to better handle escaped RegExp content in reversed links.

This commit is contained in:
David Anson 2019-09-28 14:30:16 -07:00
parent 40ac584482
commit 6587ba7261
2 changed files with 13 additions and 2 deletions

View file

@ -22,3 +22,13 @@ code code
code` text
text
text (reversed)[link] text {MD011}
## Escaped JavaScript Content
var IDENT_RE = '([a-zA-Z]|\\.[a-zA-Z.])[a-zA-Z0-9._]*'; {MD011}
begin: /\B(([\/.])[\w\-.\/=]+)+/, {MD011}
{begin: '%r\\(', end: '\\)[a-z]*'} {MD011}
return /(?:(?:(^|\/)[!.])|[*?+()|\[\]{}]|[+@]\()/.test(str); {MD011}