We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b963e9b commit 165ee2dCopy full SHA for 165ee2d
src/index.ts
@@ -550,7 +550,8 @@ export class Matcher {
550
}
551
552
553
-const kMarkupPattern = /<!--[^]*?(?=-->)-->|<(\/?)([a-z][a-z0-9]*-?[a-z0-9]*)\s*([^>]*?)(\/?)>/ig;
+// https://html.spec.whatwg.org/multipage/custom-elements.html#valid-custom-element-name
554
+const kMarkupPattern = /<!--[^]*?(?=-->)-->|<(\/?)([a-z][-.0-9_a-z]*)\s*([^>]*?)(\/?)>/ig;
555
const kAttributePattern = /(^|\s)(id|class)\s*=\s*("([^"]+)"|'([^']+)'|(\S+))/ig;
556
const kSelfClosingElements = {
557
meta: true,
0 commit comments