pull/12780/head
Rich Harris 2 years ago
parent b8b07e0128
commit 576763a167

@ -64,7 +64,7 @@ export function visit_component(node, context) {
// If the component has a slot attribute — `<Foo slot="whatever" .../>` —
// then `let:` directives apply to other attributes, instead of just the
// top-level contents of the component. Yes, this is very weird.
const default_state = !!determine_slot(node)
const default_state = determine_slot(node)
? context.state
: { ...context.state, scope: node.metadata.scopes.default };

@ -303,7 +303,7 @@ export function create_scopes(ast, root, allow_reactive_declarations, parent) {
default: context.state.scope.child()
};
const default_state = !!determine_slot(node)
const default_state = determine_slot(node)
? context.state
: { scope: node.metadata.scopes.default };

Loading…
Cancel
Save