fix: ensure backwards compat for pre-compiled sfc components

fix #3493
This commit is contained in:
Evan You
2021-03-27 10:53:45 -04:00
parent 9ff70be2b3
commit 37c17091fd
16 changed files with 278 additions and 96 deletions

View File

@@ -34,7 +34,7 @@ export const transformSlotOutlet: NodeTransform = (node, context) => {
slotArgs.push(createFunctionExpression([], children, false, false, loc))
}
if (context.slotted) {
if (context.scopeId && !context.slotted) {
if (!slotProps) {
slotArgs.push(`{}`)
}