Skip to content

Commit 9d4344d

Browse files
committed
fix(language-core): prevent infinite loop on missing closing tag
1 parent 5e2d2ce commit 9d4344d

File tree

1 file changed

+1
-1
lines changed
  • packages/language-core/lib/codegen/template

1 file changed

+1
-1
lines changed

packages/language-core/lib/codegen/template/vSlot.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ function getElementInnerLoc(
195195
while (options.template.content[start - 1] !== '>') {
196196
start--;
197197
}
198-
while (options.template.content[end] !== '<') {
198+
while (options.template.content[end] !== '<' && end < node.loc.end.offset) {
199199
end++;
200200
}
201201
return {

0 commit comments

Comments
 (0)