@@ -179,7 +179,7 @@ const tokenizer = new Tokenizer(stack, {
179179 const name = currentOpenTag ! . tag
180180 currentOpenTag ! . isSelfClosing = true
181181 endOpenTag ( end )
182- if ( stack [ 0 ] ? .tag === name ) {
182+ if ( stack [ 0 ] && stack [ 0 ] . tag === name ) {
183183 onCloseTag ( stack . shift ( ) ! , end )
184184 }
185185 } ,
@@ -587,14 +587,14 @@ function endOpenTag(end: number) {
587587
588588function onText ( content : string , start : number , end : number ) {
589589 if ( __BROWSER__ ) {
590- const tag = stack [ 0 ] ? .tag
590+ const tag = stack [ 0 ] && stack [ 0 ] . tag
591591 if ( tag !== 'script' && tag !== 'style' && content . includes ( '&' ) ) {
592592 content = currentOptions . decodeEntities ! ( content , false )
593593 }
594594 }
595595 const parent = stack [ 0 ] || currentRoot
596596 const lastNode = parent . children [ parent . children . length - 1 ]
597- if ( lastNode ? .type === NodeTypes . TEXT ) {
597+ if ( lastNode && lastNode . type === NodeTypes . TEXT ) {
598598 // merge
599599 lastNode . content += content
600600 setLocEnd ( lastNode . loc , end )
@@ -771,7 +771,8 @@ function isComponent({ tag, props }: ElementNode): boolean {
771771 tag === 'component' ||
772772 isUpperCase ( tag . charCodeAt ( 0 ) ) ||
773773 isCoreComponent ( tag ) ||
774- currentOptions . isBuiltInComponent ?.( tag ) ||
774+ ( currentOptions . isBuiltInComponent &&
775+ currentOptions . isBuiltInComponent ( tag ) ) ||
775776 ( currentOptions . isNativeTag && ! currentOptions . isNativeTag ( tag ) )
776777 ) {
777778 return true
@@ -828,8 +829,8 @@ function condenseWhitespace(
828829 if ( node . type === NodeTypes . TEXT ) {
829830 if ( ! inPre ) {
830831 if ( isAllWhitespace ( node . content ) ) {
831- const prev = nodes [ i - 1 ] ? .type
832- const next = nodes [ i + 1 ] ? .type
832+ const prev = nodes [ i - 1 ] && nodes [ i - 1 ] . type
833+ const next = nodes [ i + 1 ] && nodes [ i + 1 ] . type
833834 // Remove if:
834835 // - the whitespace is the first or last node, or:
835836 // - (condense mode) the whitespace is between two comments, or:
@@ -1063,7 +1064,7 @@ export function baseParse(input: string, options?: ParserOptions): RootNode {
10631064 currentOptions . ns === Namespaces . SVG ||
10641065 currentOptions . ns === Namespaces . MATH_ML
10651066
1066- const delimiters = options ? .delimiters
1067+ const delimiters = options && options . delimiters
10671068 if ( delimiters ) {
10681069 tokenizer . delimiterOpen = toCharCodes ( delimiters [ 0 ] )
10691070 tokenizer . delimiterClose = toCharCodes ( delimiters [ 1 ] )
0 commit comments