File tree Expand file tree Collapse file tree 1 file changed +2
-4
lines changed
packages/svelte/src/compiler/phases/1-parse/state Expand file tree Collapse file tree 1 file changed +2
-4
lines changed Original file line number Diff line number Diff line change @@ -95,8 +95,7 @@ export default function element(parser) {
9595
9696 if ( parent . type === 'RegularElement' ) {
9797 if ( ! parser . last_auto_closed_tag || parser . last_auto_closed_tag . tag !== name ) {
98- const opening_tag_end =
99- parent . fragment . nodes [ 0 ] ?. start ?? parent . start + parent . name . length + 2 ;
98+ const opening_tag_end = parent . fragment . nodes [ 0 ] ?. start ?? start ;
10099 w . element_implicitly_closed ( { start : parent . start , end : opening_tag_end } , parent . name ) ;
101100 }
102101 } else if ( ! parser . loose ) {
@@ -192,8 +191,7 @@ export default function element(parser) {
192191 parser . allow_whitespace ( ) ;
193192
194193 if ( parent . type === 'RegularElement' && closing_tag_omitted ( parent . name , name ) ) {
195- const opening_tag_end =
196- parent . fragment . nodes [ 0 ] ?. start ?? parent . start + parent . name . length + 2 ;
194+ const opening_tag_end = parent . fragment . nodes [ 0 ] ?. start ?? start ;
197195 w . element_implicitly_closed ( { start : parent . start , end : opening_tag_end } , parent . name ) ;
198196 parent . end = start ;
199197 parser . pop ( ) ;
You can’t perform that action at this time.
0 commit comments