diff --git a/lib/md033.js b/lib/md033.js index 331c70a3..6bfa0516 100644 --- a/lib/md033.js +++ b/lib/md033.js @@ -6,7 +6,7 @@ const { addError, bareUrlRe, forEachLine, unescapeMarkdown } = require("../helpers"); const { lineMetadata } = require("./cache"); -const htmlElementRe = /<(([\w-]+)(?:[\s/][^>]*)?)>/g; +const htmlElementRe = /<(([A-Za-z][A-Za-z0-9-]*)(?:[\s/][^>]*)?)>/g; const linkDestinationRe = /]\(\s*$/; const inlineCodeRe = /^[^`]*(`+[^`]+`+[^`]+)*`+[^`]*$/; // See https://spec.commonmark.org/0.29/#autolinks diff --git a/test/detailed-results-html-tags.md b/test/detailed-results-html-tags.md index 86159a0b..0bbf4773 100644 --- a/test/detailed-results-html-tags.md +++ b/test/detailed-results-html-tags.md @@ -101,5 +101,7 @@ Text is an HTML element. But is not an autolink or HTML element. +And neither is . +Nor <123abc>. Text