From 4c0405390abdf3276b6eda9e3d02541f5f1dbe45 Mon Sep 17 00:00:00 2001 From: Rich Harris Date: Tue, 11 Feb 2025 10:31:52 -0500 Subject: [PATCH] more --- .../svelte/src/internal/client/dom/blocks/boundary.js | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/packages/svelte/src/internal/client/dom/blocks/boundary.js b/packages/svelte/src/internal/client/dom/blocks/boundary.js index bdef1453ac..e3f4bd161a 100644 --- a/packages/svelte/src/internal/client/dom/blocks/boundary.js +++ b/packages/svelte/src/internal/client/dom/blocks/boundary.js @@ -66,6 +66,9 @@ export class Boundary { /** @type {BoundaryProps} */ #props; + /** @type {((anchor: Node) => void)} */ + #children; + /** @type {Effect} */ #effect; @@ -102,6 +105,8 @@ export class Boundary { constructor(node, props, children) { this.#anchor = node; this.#props = props; + this.#children = children; + this.parent = active_boundary; active_boundary = this; @@ -126,7 +131,7 @@ export class Boundary { this.#is_creating_fallback = false; try { - return branch(() => children(this.#anchor)); + return branch(() => this.#children(this.#anchor)); } finally { reset_is_throwing_error(); } @@ -220,7 +225,7 @@ export class Boundary { destroy_effect(/** @type {Effect} */ (this.#pending_effect)); this.#main_effect = this.#run(() => { - return branch(() => children(this.#anchor)); + return branch(() => this.#children(this.#anchor)); }); }); } else {