Skip to content

Commit 35e2afe

Browse files
committed
fix: test for simple_set and simple_set
1 parent 873cd5f commit 35e2afe

File tree

2 files changed

+3
-1
lines changed
  • packages/svelte

2 files changed

+3
-1
lines changed

packages/svelte/src/internal/client/reactivity/sources.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -225,6 +225,8 @@ export function simple_set(source, value, should_proxy = false, needs_previous =
225225

226226
source.v = new_value;
227227

228+
source.o?.onchange?.();
229+
228230
return new_value;
229231
}
230232

packages/svelte/tests/runtime-runes/samples/state-onchange/main.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
3838
3939
constructor(){
40-
this.#in_constructor++;
40+
this.#in_constructor = 42;
4141
this.#in_constructor_proxy.count++;
4242
}
4343
}

0 commit comments

Comments
 (0)