fix(Suspense): fallback should work with transition (#3968)

fix #3963
This commit is contained in:
edison
2021-06-22 04:58:43 +08:00
committed by GitHub
parent 08e93220f1
commit 43e2a72900
2 changed files with 65 additions and 1 deletions

View File

@@ -551,6 +551,8 @@ function createSuspenseBoundary(
if (delayEnter) {
activeBranch!.transition!.afterLeave = mountFallback
}
suspense.isInFallback = true
// unmount current active branch
unmount(
activeBranch!,
@@ -559,7 +561,6 @@ function createSuspenseBoundary(
true // shouldRemove
)
suspense.isInFallback = true
if (!delayEnter) {
mountFallback()
}