[FIX] compiler: slot are called with a specific and different key

This commit is contained in:
Lucas Perais (lpe)
2022-01-14 15:29:00 +01:00
committed by Aaron Bohy
parent 6a7703ea82
commit cec451fd15
3 changed files with 133 additions and 0 deletions
+1
View File
@@ -32,6 +32,7 @@ function callSlot(
extra: any,
defaultContent?: (ctx: any, node: any, key: string) => BDom
): BDom {
key = key + "__slot_" + name;
const slots = (ctx.props && ctx.props.slots) || {};
const { __render, __ctx, __scope } = slots[name] || {};
const slotScope = Object.create(__ctx || {});