Browse Source

chore: minor tweaks

daiwei 1 year ago
parent
commit
6c17a3713f
1 changed files with 1 additions and 1 deletions
  1. 1 1
      packages/compiler-core/src/transforms/vSlot.ts

+ 1 - 1
packages/compiler-core/src/transforms/vSlot.ts

@@ -413,7 +413,7 @@ function hasForwardedSlots(children: TemplateChildNode[]): boolean {
         if (hasForwardedSlots(child.branches)) return true
         if (hasForwardedSlots(child.branches)) return true
         break
         break
       case NodeTypes.SKIP:
       case NodeTypes.SKIP:
-        const consequent = child.consequent
+        const { consequent } = child
         if (
         if (
           (consequent.type === NodeTypes.IF_BRANCH &&
           (consequent.type === NodeTypes.IF_BRANCH &&
             hasForwardedSlots(consequent.children)) ||
             hasForwardedSlots(consequent.children)) ||