-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: account for mutations in script module in ownership check (#14253)
- Loading branch information
1 parent
7bc94b9
commit ae9f53a
Showing
4 changed files
with
21 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'svelte': patch | ||
--- | ||
|
||
fix: account for mutations in script module in ownership check |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 7 additions & 0 deletions
7
packages/svelte/tests/runtime-runes/samples/mutate-state-in-context-dev/_config.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
import { test } from '../../test'; | ||
|
||
export default test({ | ||
compileOptions: { | ||
dev: true | ||
} | ||
}); |
6 changes: 6 additions & 0 deletions
6
packages/svelte/tests/runtime-runes/samples/mutate-state-in-context-dev/main.svelte
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
<script module> | ||
let obj = $state({}); | ||
obj.test = "hi!"; | ||
</script> | ||
|
||
<h1>Values: {JSON.stringify(obj)}</h1> |