wip(compiler): improve node stringification to support adjacent nodes
This commit is contained in:
@@ -54,10 +54,7 @@ function walk(
|
||||
// whole tree is static
|
||||
;(child.codegenNode as VNodeCall).patchFlag =
|
||||
PatchFlags.HOISTED + (__DEV__ ? ` /* HOISTED */` : ``)
|
||||
const hoisted = context.transformHoist
|
||||
? context.transformHoist(child, context)
|
||||
: child.codegenNode!
|
||||
child.codegenNode = context.hoist(hoisted)
|
||||
child.codegenNode = context.hoist(child.codegenNode!)
|
||||
continue
|
||||
} else {
|
||||
// node may contain dynamic children, but its props may be eligible for
|
||||
@@ -100,6 +97,10 @@ function walk(
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (context.transformHoist) {
|
||||
context.transformHoist(children, context)
|
||||
}
|
||||
}
|
||||
|
||||
export function isStaticNode(
|
||||
|
||||
Reference in New Issue
Block a user