Update MD034/no-bare-urls to ignore "[link]" scenario that conflicts with MD011/no-reversed-links (fixes #268).

This commit is contained in:
David Anson 2020-04-01 20:21:36 -07:00
parent 29f16bf402
commit dd66a33d75
8 changed files with 60 additions and 27 deletions

View file

@ -21,7 +21,7 @@ const inlineCommentRe =
module.exports.inlineCommentRe = inlineCommentRe;
// Regular expressions for range matching
module.exports.bareUrlRe = /(?:http|ftp)s?:\/\/[^\s]*/ig;
module.exports.bareUrlRe = /(?:http|ftp)s?:\/\/[^\s\]]*/ig;
module.exports.listItemMarkerRe = /^([\s>]*)(?:[*+-]|\d+[.)])\s+/;
module.exports.orderedListItemMarkerRe = /^[\s>]*0*(\d+)[.)]/;