Skip to content

Commit bcf6b6a

Browse files
authored
(chore) bump Svelte version (#1474)
support for const in if blocks in new transformation #1470
1 parent bb58b0c commit bcf6b6a

File tree

6 files changed

+36
-6
lines changed

6 files changed

+36
-6
lines changed

packages/language-server/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@
5454
"lodash": "^4.17.21",
5555
"prettier": "2.5.1",
5656
"prettier-plugin-svelte": "~2.7.0",
57-
"svelte": "^3.47.0",
57+
"svelte": "^3.48.0",
5858
"svelte-preprocess": "~4.10.1",
5959
"svelte2tsx": "~0.5.0",
6060
"typescript": "*",

packages/svelte2tsx/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
"rollup-plugin-delete": "^2.0.0",
3535
"source-map-support": "^0.5.16",
3636
"sourcemap-codec": "^1.4.8",
37-
"svelte": "~3.47.0",
37+
"svelte": "~3.48.0",
3838
"tiny-glob": "^0.2.6",
3939
"tslib": "^1.10.0",
4040
"typescript": "^4.6.2"
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
<>{(name == "world") ? <>
2+
{@const hello = name}
3+
<h1>Hello {hello}</h1>
4+
</> : (true) ? <>
5+
{@const hello = name}
6+
<h1>Hello {hello}</h1>
7+
</> : <>
8+
{@const hello = name}
9+
<h1>Hello {hello}</h1>
10+
</> }</>
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
if(name == "world"){
2+
const hello = name;
3+
{ svelteHTML.createElement("h1", {}); hello; }
4+
} else if (true){
5+
const hello = name;
6+
{ svelteHTML.createElement("h1", {}); hello; }
7+
}else{
8+
const hello = name;
9+
{ svelteHTML.createElement("h1", {}); hello; }
10+
}
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
{#if name == "world"}
2+
{@const hello = name}
3+
<h1>Hello {hello}</h1>
4+
{:else if true}
5+
{@const hello = name}
6+
<h1>Hello {hello}</h1>
7+
{:else}
8+
{@const hello = name}
9+
<h1>Hello {hello}</h1>
10+
{/if}

yarn.lock

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2539,10 +2539,10 @@ svelte-preprocess@~4.10.1:
25392539
sorcery "^0.10.0"
25402540
strip-indent "^3.0.0"
25412541

2542-
svelte@^3.47.0, svelte@~3.47.0:
2543-
version "3.47.0"
2544-
resolved "https://registry.yarnpkg.com/svelte/-/svelte-3.47.0.tgz#ba46fe4aea99fc650d6939c215cd4694f5325a19"
2545-
integrity sha512-4JaJp3HEoTCGARRWZQIZDUanhYv0iyoHikklVHVLH9xFE9db22g4TDv7CPeNA8HD1JgjXI1vlhR1JZvvhaTu2Q==
2542+
svelte@^3.48.0, svelte@~3.48.0:
2543+
version "3.48.0"
2544+
resolved "https://registry.yarnpkg.com/svelte/-/svelte-3.48.0.tgz#f98c866d45e155bad8e1e88f15f9c03cd28753d3"
2545+
integrity sha512-fN2YRm/bGumvjUpu6yI3BpvZnpIm9I6A7HR4oUNYd7ggYyIwSA/BX7DJ+UXXffLp6XNcUijyLvttbPVCYa/3xQ==
25462546

25472547
table@^5.2.3:
25482548
version "5.4.6"

0 commit comments

Comments
 (0)