Skip to content

Commit

Permalink
fix(ssr): fix dynamic slot regression in ssr
Browse files Browse the repository at this point in the history
  • Loading branch information
yyx990803 authored and chrislone committed Feb 4, 2023
1 parent 8c560d0 commit 596ce50
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion packages/runtime-core/src/helpers/createSlots.ts
Expand Up @@ -33,7 +33,8 @@ export function createSlots(
const res = slot.fn(...args)
// attach branch key so each conditional branch is considered a
// different fragment
;(res as any).key = slot.key
// #6651 res can be undefined in SSR in string push mode
if (res) (res as any).key = slot.key
return res
}
: slot.fn
Expand Down

0 comments on commit 596ce50

Please sign in to comment.