feat(compiler/slot): bail out of optimization mode for non-compiled slots
This commit is contained in:
@@ -409,7 +409,7 @@ export function createRenderer<
|
||||
invokeDirectiveHook(newProps.vnodeBeforeUpdate, parentComponent, n2, n1)
|
||||
}
|
||||
|
||||
if (patchFlag) {
|
||||
if (patchFlag > 0) {
|
||||
// the presence of a patchFlag means this element's render code was
|
||||
// generated by the compiler and can take the fast path.
|
||||
// in this path old node and new node are guaranteed to have the same shape
|
||||
@@ -1227,9 +1227,12 @@ export function createRenderer<
|
||||
const prevShapeFlag = n1 ? n1.shapeFlag : 0
|
||||
const c2 = n2.children
|
||||
|
||||
// fast path
|
||||
const { patchFlag, shapeFlag } = n2
|
||||
if (patchFlag) {
|
||||
if (patchFlag === PatchFlags.BAIL) {
|
||||
optimized = false
|
||||
}
|
||||
// fast path
|
||||
if (patchFlag > 0) {
|
||||
if (patchFlag & PatchFlags.KEYED_FRAGMENT) {
|
||||
// this could be either fully-keyed or mixed (some keyed some not)
|
||||
// presence of patchFlag means children are guaranteed to be arrays
|
||||
|
||||
Reference in New Issue
Block a user