Skip to content

Commit 594d35e

Browse files
committed
fix: Use STATE_SYMBOL to de-proxy component in unmount (#16656)
1 parent 08b3b66 commit 594d35e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/svelte/src/internal/client/render.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -301,7 +301,7 @@ let mounted_components = new WeakMap();
301301
* @returns {Promise<void>}
302302
*/
303303
export function unmount(component, options) {
304-
const fn = mounted_components.get(component);
304+
const fn = mounted_components.get(component[STATE_SYMBOL]);
305305

306306
if (fn) {
307307
mounted_components.delete(component);

0 commit comments

Comments
 (0)