Implement markdownlint-disable-next-line inline comment (fixes #295).

This commit is contained in:
David Anson 2020-11-22 14:02:36 -08:00
parent bd63c57fde
commit a6d30cb724
4 changed files with 51 additions and 8 deletions

View file

@ -17,7 +17,7 @@ module.exports.frontMatterRe =
// Regular expression for matching inline disable/enable comments
const inlineCommentRe =
// eslint-disable-next-line max-len
/<!--\s*markdownlint-(?:(?:(disable|enable|capture|restore|disable-file|enable-file)((?:\s+[a-z0-9_-]+)*))|(?:(configure-file)\s+([\s\S]*?)))\s*-->/ig;
/<!--\s*markdownlint-(?:(?:(disable|enable|capture|restore|disable-file|enable-file|disable-next-line)((?:\s+[a-z0-9_-]+)*))|(?:(configure-file)\s+([\s\S]*?)))\s*-->/ig;
module.exports.inlineCommentRe = inlineCommentRe;
// Regular expressions for range matching