Skip to content

2025/01/21 迄の更新に追従 #15

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 171 commits into from
Jan 22, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
171 commits
Select commit Hold shift + click to select a range
220fb5e
docs: Fix Typo in advanced tutorial (#863)
broemp Nov 13, 2024
e88231b
docs: tweak tutorial (#879)
laelhalawani Nov 25, 2024
799fd0f
fix: repl example '<svelte:document>' (#871)
delight Nov 25, 2024
0b7a0cb
fix: resolve `module` and `browser` conditions for fetched packages i…
Andarist Nov 25, 2024
a9367a4
feat: add vim mode via query param (#813)
Rich-Harris Nov 25, 2024
d401d8c
fix: update all $state.frozen autocomplete sugestions to $state.raw (…
Thiagolino8 Nov 26, 2024
e80d79d
Sync `svelte` docs (#826)
github-actions[bot] Nov 26, 2024
1b686b8
Sync `kit` docs (#828)
github-actions[bot] Nov 26, 2024
8aa34c1
fix: incorrect value in <select> element. (#894)
vhtmui Nov 29, 2024
0b3567e
Sync `kit` docs (#897)
github-actions[bot] Nov 30, 2024
4486c85
Sync `cli` docs (#898)
github-actions[bot] Nov 30, 2024
9d357d2
Sync `svelte` docs (#901)
github-actions[bot] Nov 30, 2024
229e7b1
Sync `svelte` docs (#903)
github-actions[bot] Dec 1, 2024
f7acf37
install @cloudflare/workers-types (#905)
Rich-Harris Dec 1, 2024
4821d7c
Sync `kit` docs (#906)
github-actions[bot] Dec 1, 2024
125c7ef
docs: error boundary tutorial (#893)
dummdidumm Dec 1, 2024
9b8b817
add advent of svelte blog post (#904)
Rich-Harris Dec 1, 2024
a865f37
Sync `svelte` docs (#907)
github-actions[bot] Dec 1, 2024
1368a7a
Sync `svelte` docs (#908)
github-actions[bot] Dec 2, 2024
9d97da3
advent of svelte day 2 (#909)
Rich-Harris Dec 2, 2024
4f819ed
Sync `svelte` docs (#910)
github-actions[bot] Dec 2, 2024
2efd674
fix: resolve incorrect link activation for first and last sections (#…
Vardhaman619 Dec 2, 2024
0cf5e7e
chore: advent of svelte banner (#914)
Rich-Harris Dec 2, 2024
83ae719
docs: "What's new in Svelte" November newsletter (#881)
DreaminDani Dec 2, 2024
8f8ae89
Bigints (#916)
Rich-Harris Dec 2, 2024
08c787d
include classes in exports (#917)
Rich-Harris Dec 2, 2024
b87845a
Sync `svelte` docs (#918)
github-actions[bot] Dec 3, 2024
1666909
docs: update sample code to replace deprecated <svelte:component> (#919)
nanggo Dec 3, 2024
04be0aa
docs: adjust blog example (#920)
dominikg Dec 3, 2024
6fb7411
Sync `svelte` docs (#922)
github-actions[bot] Dec 3, 2024
e24407c
advent of svelte day 3 — exported snippets (#924)
Rich-Harris Dec 3, 2024
f02876b
Sync `svelte` docs (#923)
github-actions[bot] Dec 3, 2024
c8f62af
Sync `kit` docs (#921)
github-actions[bot] Dec 3, 2024
0d2d24f
fix: add polyfills / avoid using `structuredClone` (#915)
dummdidumm Dec 3, 2024
42bd7b8
Sync `svelte` docs (#926)
github-actions[bot] Dec 4, 2024
cbf9f29
Sync `svelte` docs (#928)
github-actions[bot] Dec 4, 2024
fb84f19
Sync `kit` docs (#929)
github-actions[bot] Dec 4, 2024
0709259
advent of svelte day 4 (#930)
Rich-Harris Dec 4, 2024
fac2647
consistency
Rich-Harris Dec 4, 2024
2c8542a
Sync `svelte` docs (#932)
github-actions[bot] Dec 5, 2024
ea6528e
fix deprecated note styles (#937)
Rich-Harris Dec 5, 2024
5b9f2ec
Sync `svelte` docs (#938)
github-actions[bot] Dec 5, 2024
3ba6329
advent of svelte day 5 (#939)
Rich-Harris Dec 5, 2024
140dbff
feat: Render full posts on RSS feed (#934)
martgnz Dec 5, 2024
044c08d
strip origin from links in deprecation notices (#941)
Rich-Harris Dec 5, 2024
c478ec8
Sync `svelte` docs (#940)
github-actions[bot] Dec 5, 2024
9c12b0e
prerender RSS feed (#943)
Rich-Harris Dec 5, 2024
b0165dd
Sync `svelte` docs (#944)
github-actions[bot] Dec 6, 2024
0b27a96
Motion tutorials (#949)
Rich-Harris Dec 6, 2024
fb5eb6d
Sync `svelte` docs (#946)
github-actions[bot] Dec 6, 2024
16aab59
day 6 (#950)
Rich-Harris Dec 6, 2024
4bafbe6
docs: Remove duplicate info about {#each} block (#953)
Thiagolino8 Dec 7, 2024
b1cb6c7
better nav (#933)
Rich-Harris Dec 7, 2024
2f44045
Fix: grammar fix in index.md (#948)
liamvgallagher Dec 7, 2024
7b7abe9
Sync `svelte` docs (#951)
github-actions[bot] Dec 7, 2024
808116b
Sync `kit` docs (#952)
github-actions[bot] Dec 7, 2024
46bd8b9
Advent of svelte day 7 (#956)
Rich-Harris Dec 7, 2024
d4db2b1
chore: update REPL autocomplete (remove `$state.is`, `on:` directive,…
Ocean-OS Dec 7, 2024
c9c48fb
Sync `kit` docs (#958)
github-actions[bot] Dec 8, 2024
6b50faa
Sync `svelte` docs (#959)
github-actions[bot] Dec 8, 2024
d964e0b
docs: Advent day 8 (#960)
Rich-Harris Dec 8, 2024
c917b47
oops i meant to say this
Rich-Harris Dec 8, 2024
b53b691
chore: Update comments on utils.js for clarity and accuracy (#963)
ajatamayo Dec 9, 2024
d697639
fix: make Safari rendering of summary elements the same as other brow…
BernieSumption Dec 9, 2024
337799e
fix: Update package version of codemirror/view to fix carret low cont…
heygwangjin Dec 9, 2024
2f51473
feat: add stable route for all warning/error codes (#965)
dummdidumm Dec 9, 2024
a82171f
Sync `svelte` docs (#968)
github-actions[bot] Dec 9, 2024
fd48fb1
add links to console output (#967)
Rich-Harris Dec 9, 2024
01a731d
docs: advent day 9 (#969)
Rich-Harris Dec 9, 2024
912e907
Sync `kit` docs (#972)
github-actions[bot] Dec 10, 2024
4939db6
day 10 (#973)
Rich-Harris Dec 10, 2024
d6a64f8
chore: upgrade enhanced-img and @vercel/speed-insights (#970)
benmccann Dec 10, 2024
a2ba79d
add banner discouraging people from editing generated files (#966)
Rich-Harris Dec 10, 2024
25ea0c8
Revert "fix: Update package version of codemirror/view to fix carret …
Rich-Harris Dec 10, 2024
03e3066
chore: upgrade SvelteKit (#977)
benmccann Dec 10, 2024
e9565fe
chore: upgrade svelte-json-tree to fix peer dep warning (#980)
benmccann Dec 11, 2024
fc61a81
Sync `kit` docs (#984)
github-actions[bot] Dec 11, 2024
645ddef
Sync `svelte` docs (#988)
github-actions[bot] Dec 11, 2024
40e4152
day 11 (#989)
Rich-Harris Dec 11, 2024
7487ef1
fix: correct GH issues link on 404 page (#986)
Conduitry Dec 11, 2024
b167c13
fix: account for section-less pages during code redirects (#990)
dummdidumm Dec 11, 2024
be6e3a6
fix: include .env files in tutorial assets (#987)
jpaquim Dec 11, 2024
14edd76
support importing different versions of packages (#992)
Rich-Harris Dec 11, 2024
0be535c
Sync `svelte` docs (#991)
github-actions[bot] Dec 11, 2024
65825d3
Sync `svelte` docs (#994)
github-actions[bot] Dec 11, 2024
a8cff16
Sync `kit` docs (#998)
github-actions[bot] Dec 12, 2024
14871fc
day 12 (#1001)
Rich-Harris Dec 12, 2024
24bb288
import correct version, as determined by package.json (#1006)
Rich-Harris Dec 12, 2024
36211f3
better commonjs support (#1007)
Rich-Harris Dec 12, 2024
5e1deac
Sync `svelte` docs (#1005)
github-actions[bot] Dec 12, 2024
5bf008e
chore: fix some dependabot security warnings (#1002)
benmccann Dec 12, 2024
ad86cb3
Fix Responsive Issue in svelte.dev Homepage (#997)
kresnasatya Dec 12, 2024
1cb4969
chore: Upgrade CodeMirror (#978)
Rich-Harris Dec 12, 2024
6c7779b
chore: remove use of deprecated `xlink` attribute (#996)
benmccann Dec 12, 2024
ba1163f
trim ts snippets (#945)
Rich-Harris Dec 13, 2024
7416468
use local version of svelte (#1009)
Rich-Harris Dec 13, 2024
d2c90f6
fix: restore surrounding newlines with `lang="ts"` (#1011)
KazariEX Dec 13, 2024
99b16ef
feat: llms.txt (#979)
khromov Dec 13, 2024
9d38b38
fix: state_proxy_equality_mismatch error in deferred-transitions exam…
Thiagolino8 Dec 13, 2024
09b9b2c
Sync `cli` docs (#1013)
github-actions[bot] Dec 14, 2024
8b63b6e
Sync `svelte` docs (#1014)
github-actions[bot] Dec 14, 2024
a39bd44
Sync `svelte` docs (#1015)
github-actions[bot] Dec 15, 2024
68718e3
Sync `kit` docs (#1017)
github-actions[bot] Dec 15, 2024
44f55ea
Sync `svelte` docs (#1019)
github-actions[bot] Dec 15, 2024
f3dbf96
bump svelte, transfer errors (#1020)
Rich-Harris Dec 15, 2024
81f8130
day 15 (#1021)
Rich-Harris Dec 15, 2024
198e9f1
Sync `kit` docs (#1022)
github-actions[bot] Dec 16, 2024
c415524
Sync `kit` docs (#1025)
github-actions[bot] Dec 16, 2024
45a18ab
autocomplete `$inspect.trace()` (#1023)
Rich-Harris Dec 16, 2024
7be3ae3
Sync `kit` docs (#1026)
github-actions[bot] Dec 16, 2024
989d67f
Sync `cli` docs (#1027)
github-actions[bot] Dec 16, 2024
ad223f3
App state tutorial (#1016)
dummdidumm Dec 16, 2024
5d6586b
day 16 (#1029)
Rich-Harris Dec 16, 2024
058089f
run app-state migration (#1030)
Rich-Harris Dec 16, 2024
db2cbee
Sync `cli` docs (#1028)
github-actions[bot] Dec 16, 2024
45926cc
bump svelte-split-pane (#1031)
Rich-Harris Dec 17, 2024
9985efa
Panel UI (#1032)
Rich-Harris Dec 17, 2024
aa7e00e
fix: replace incorrect jsdoc typeExpression in AST traversal (#1018)
domuk-k Dec 17, 2024
bddf9f6
day 17 (#1033)
Rich-Harris Dec 17, 2024
2f8b59d
Sync `svelte` docs (#1034)
github-actions[bot] Dec 17, 2024
59ff625
fix cursor position on state changes (#1035)
Rich-Harris Dec 18, 2024
ca13b39
feat: highlight hovered nodes (#902)
Rich-Harris Dec 18, 2024
2ed7da6
day 18 (#1038)
Rich-Harris Dec 18, 2024
db463c2
Sync `svelte` docs (#1041)
github-actions[bot] Dec 18, 2024
ee4395c
Sync `kit` docs (#1044)
github-actions[bot] Dec 19, 2024
d88895c
day 19 (#1045)
Rich-Harris Dec 19, 2024
cdcdea6
bump prettier-plugin-svelte (#1048)
Rich-Harris Dec 20, 2024
1a008bd
make prerender configurable (#1050)
Rich-Harris Dec 20, 2024
1e037e2
Vim UI (#1049)
Rich-Harris Dec 20, 2024
8c80acd
day 20 (#1052)
Rich-Harris Dec 20, 2024
89282d2
Sync `kit` docs (#1054)
github-actions[bot] Dec 21, 2024
3766e33
day 21 (#1055)
Rich-Harris Dec 21, 2024
471942d
Sync `kit` docs (#1057)
github-actions[bot] Dec 22, 2024
3eaa4b9
day 22 (#1058)
Rich-Harris Dec 22, 2024
a940812
docs: use root-relative links instead of https://svelte.dev (#1061)
Rich-Harris Dec 23, 2024
6e4cbb3
feat: "download app" possibility (#1051)
dummdidumm Dec 23, 2024
cfa3d8c
day 23 (#1062)
Rich-Harris Dec 23, 2024
97ad9c1
chore: add title to root docs page (#1060)
hyunbinseo Dec 23, 2024
13a22b2
Sync `svelte` docs (#1065)
github-actions[bot] Dec 24, 2024
c961a08
strip origin in more places (#1067)
Rich-Harris Dec 24, 2024
037f046
update class tutorial (#1063)
Rich-Harris Dec 24, 2024
e567c6c
day 24 (#1068)
Rich-Harris Dec 24, 2024
3afb347
docs: "What's new in Svelte" January newsletter (#1059)
DreaminDani Jan 1, 2025
414fba4
Sync `kit` docs (#1070)
github-actions[bot] Jan 6, 2025
83e7d2d
fix: added Svelte version check to runes widget in Playground (#1072)
ThePaSch Jan 6, 2025
ced06c3
fix: Add missing {@render children()} in tutorial (#1073)
varholak-peter Jan 6, 2025
30648d0
respect system theme, without FOUC (#1087)
Rich-Harris Jan 6, 2025
13a0f50
fix: Improve the readability of 05-keyed-each-blocks in tutorial (#1071)
nikolaiborbe Jan 6, 2025
aa18988
feat: change RSS feed pubDate and items order (#1077)
jsafarik Jan 6, 2025
375fa3b
remove svelte-persisted-store (#1088)
Rich-Harris Jan 6, 2025
5c49543
Fix: SvelteKit post-handlers tutorial (#1085)
twobitfool Jan 6, 2025
2b6bcc8
Fix: SvelteKit other-handlers tutorial (#1086)
twobitfool Jan 6, 2025
1752dea
fix: repl redirect to playground (#1089)
PuruVJ Jan 6, 2025
a6e93ea
oops (#1090)
Rich-Harris Jan 6, 2025
de5ce63
Sync `svelte` docs (#1091)
github-actions[bot] Jan 7, 2025
83881c6
Sync `svelte` docs (#1092)
github-actions[bot] Jan 7, 2025
8b56182
chore: markdown rendering fixes (#1094)
dummdidumm Jan 7, 2025
b8e19ba
Sync `svelte` docs (#1095)
github-actions[bot] Jan 7, 2025
d366515
Sync `svelte` docs (#1097)
github-actions[bot] Jan 8, 2025
66121df
Sync `svelte` docs (#1098)
github-actions[bot] Jan 8, 2025
ab7481b
Sync `svelte` docs (#1100)
github-actions[bot] Jan 8, 2025
4c54849
Sync `svelte` docs (#1101)
github-actions[bot] Jan 9, 2025
4dc828e
docs: remove useless private fields (#1102)
Rich-Harris Jan 9, 2025
1118ced
Sync `cli` docs (#1103)
github-actions[bot] Jan 9, 2025
8a182ce
fix: using `u` as in the description (#1106)
Shchvova Jan 13, 2025
17c672a
tutorial: Update css in App.svelte in a and b examples to make displa…
laelhalawani Jan 13, 2025
8422db4
docs: Fixed TODO id in animation tutorial (#1108)
F2 Jan 13, 2025
e4cdbe6
fix: prevent FOUC for theme (#1110)
paoloricciuti Jan 16, 2025
78f401b
Sync `kit` docs (#1105)
github-actions[bot] Jan 20, 2025
d160b19
Sync `svelte` docs (#1104)
github-actions[bot] Jan 20, 2025
90964b9
Merge remote-tracking branch 'sveltejs/main' into sync-upstream-20250121
tomoam Jan 22, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
3 changes: 3 additions & 0 deletions apps/svelte.dev/.env
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,6 @@ SUPABASE_KEY=

GITHUB_CLIENT_ID=
GITHUB_CLIENT_SECRET=

# disable prerendering with `PRERENDER=false pnpm build` — this is useful for speeding up builds when previewing locally
PRERENDER=true
2 changes: 2 additions & 0 deletions apps/svelte.dev/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
/src/routes/_home/Supporters/contributors.js
/src/routes/_home/Supporters/donors.jpg
/src/routes/_home/Supporters/donors.js
/scripts/svelte-template
/static/svelte-template.json

# git-repositories of synced docs go here
/repos/
Expand Down
8 changes: 8 additions & 0 deletions apps/svelte.dev/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,11 @@ When writing content for the tutorial, you need to be aware of the differences o
### Dependencies

If you look in the site's package.json you'll notice several dependencies that don't appear to be used, such as `@testing-library/svelte`. These are present because they're referenced in the docs, and Twoslash needs to be able to find type definitions in order to typecheck snippets. Installing the dependencies was deemed preferable to faking it with `declare module`, since we're liable to end up with fictional types that way.

### Prerendering

Most of the site is prerendered. Since that involves some fairly expensive work, it can take a while. To build the site _without_ prerendering — for example, because you need to debug an issue that's affecting production builds — set the `PRERENDER` environment variable to `false`:

```bash
PRERENDER=false pnpm build
```
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ authorURL: https://dreamindani.com

## SvelteとLanguageツールの新着情報(New in Svelte & Language Tools)

- Slotted components (`<svelte:fragment slot="...">`を含む) を使用すると、コンポーネントの利用者が特定のスロットにリッチなコンテンツを割り当てることができます (**Svelte 3.35.0, Language Tools [104.5.0](https://github.com/sveltejs/language-tools/releases/tag/extensions-104.5.0)**, [docs](/docs/special-elements#svelte-fragment) と [tutorial](https://svelte.jp/tutorial/svelte-fragment) をチェックしてみてください)
- Slotted components (`<svelte:fragment slot="...">`を含む) を使用すると、コンポーネントの利用者が特定のスロットにリッチなコンテンツを割り当てることができます (**Svelte 3.35.0, Language Tools [104.5.0](https://github.com/sveltejs/language-tools/releases/tag/extensions-104.5.0)**)
- Linked editing がSvelteファイル内のHTMLで機能するようになりました (**Language Tools, [104.6.0](https://github.com/sveltejs/language-tools/releases/tag/extensions-104.6.0)**)
- 型定義 `svelte.d.ts` が正常に解決されるようになり、ライブラリの作成者がSvelteコンポーネントと一緒に型定義を配布できるようになりました (**Language Tools, [104.7.0](https://github.com/sveltejs/language-tools/releases/tag/extensions-104.7.0)**)
- ViteでSvelteを使用するのに [vite-plugin-svelte](https://github.com/sveltejs/vite-plugin-svelte) が利用可能になりました。`npm init @vitejs/app` はこのプラグインを使用したSvelteオプションが含まれています。
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,7 @@ export const load: PageServerLoad = () => {
};
```

<<<<<<< HEAD
SvelteKit は自動的にこの `fetchPost` の呼び出しを await してからページのレンダリングを開始します。なぜならそれがトップレベルだからです。しかし、ネストした `fetchComments` の呼び出しが完了するのは待ちません – ページはレンダリングされ、`data.streamed.comments` はリクエストが完了すると解決する promise となります。`+page.svelte` で、Svelte の [await block](/docs/logic-blocks#await) を使用してロード中の状態を表示することもできます:
=======
SvelteKit will automatically await the `fetchPost` call before it starts rendering the page, since it’s at the top level. However, it won’t wait for the nested `fetchComments` call to complete – the page will render and `data.streamed.comments` will be a promise that will resolve as the request completes. We can show a loading state in the corresponding `+page.svelte` using Svelte’s [await block](/docs/svelte/await):
>>>>>>> sveltejs/main
SvelteKit は自動的にこの `fetchPost` の呼び出しを await してからページのレンダリングを開始します。なぜならそれがトップレベルだからです。しかし、ネストした `fetchComments` の呼び出しが完了するのは待ちません – ページはレンダリングされ、`data.streamed.comments` はリクエストが完了すると解決する promise となります。`+page.svelte` で、Svelte の [await block](/docs/svelte/await) を使用してロード中の状態を表示することもできます:

```svelte
<script lang="ts">
Expand Down Expand Up @@ -125,11 +121,7 @@ const data = {

注意事項: この機能には JavaScript が必要です。そのため、重要でないデータのみ、ストリーミングすることを推奨します。すべてのユーザーがエクスペリエンスのコアを利用できるようにするためです。

<<<<<<< HEAD
この機能の詳細については、[ドキュメント](https://kit.svelte.jp/docs/load#streaming-with-promises)をご覧ください。デモは [sveltekit-on-the-edge.vercel.app](https://sveltekit-on-the-edge.vercel.app/edge) (ロケーションデータをわざと遅延させ、ストリーミングしています) でご覧頂けますし、[ご自身で Vercel にデプロイ](https://vercel.com/templates/svelte/sveltekit-edge-functions)することもできます。Vercel では Edge Functions と Serverless Functions のどちらもストリーミングをサポートしています。
=======
For more on this feature, see [the documentation](/docs/kit/load#Streaming-with-promises). You can see a demo at [sveltekit-on-the-edge.vercel.app](https://sveltekit-on-the-edge.vercel.app/edge) (the location data is artificially delayed and streamed in) or [deploy your own on Vercel](https://vercel.com/templates/svelte/sveltekit-edge-functions), where streaming is supported in both Edge Functions and Serverless Functions.
>>>>>>> sveltejs/main
この機能の詳細については、[ドキュメント](/docs/kit/load#Streaming-with-promises)をご覧ください。デモは [sveltekit-on-the-edge.vercel.app](https://sveltekit-on-the-edge.vercel.app/edge) (ロケーションデータをわざと遅延させ、ストリーミングしています) でご覧頂けますし、[ご自身で Vercel にデプロイ](https://vercel.com/templates/svelte/sveltekit-edge-functions)することもできます。Vercel では Edge Functions と Serverless Functions のどちらもストリーミングをサポートしています。

私たちは、Qwik、Remix、Solid、Marko、React などの、このアイデアの先行実装からインスピレーションを受けました。深く感謝します。

Expand Down Expand Up @@ -162,19 +154,11 @@ For more on this feature, see [the documentation](/docs/kit/load#Streaming-with-

フォームの input の値やスクロールポジションなどは一般的な例で、JSON-serializable なデータならなんでも snapshot に保存することができます。snapshot のデータは [sessionStorage](https://developer.mozilla.org/ja/docs/Web/API/Window/sessionStorage) に保存されるので、ページがリロードされたときや、ユーザーがまったく別のサイトに移動したときにも保持されます。`sessionStorage` に保存されるため、サーバーサイドレンダリング中にアクセスすることはできません。

<<<<<<< HEAD
詳細は、[ドキュメント](https://kit.svelte.jp/docs/snapshots)をご覧ください。
詳細は、[ドキュメント](/docs/kit/snapshots)をご覧ください。

## Route-level deployment configuration

SvelteKit はプラットフォームごとに固有の [adapter](https://kit.svelte.jp/docs/adapters) を使用してプロダクションへのデプロイ用にアプリのコードを変換しています。これまでは、デプロイメントの設定をアプリ全体レベルで行わなければなりませんでした。例えば、アプリを edge function としてデプロイするか、serverless function としてデプロイするか、どちらか一方は可能でしたが、両方同時に行うことはできませんでした。これでは、アプリの一部だけを edge にするというメリットを得ることができません – もし Node API を必要とするルート(route)がある場合、アプリ全体を edge にデプロイすることができないのです。リージョンの選択やメモリ割り当てなど、デプロイ設定の他の側面についても同様です: アプリ全体、すべてのルート(route)に適用される1つの値を選択しなければならなかったのです。
=======
For more, see [the documentation](/docs/kit/snapshots).

## Route-level deployment configuration

SvelteKit uses platform-specific [adapters](/docs/kit/adapters) to transform your app code for deployment to production. Until now, you had to configure your deployment on an app-wide level. For instance, you could either deploy your app as an edge function or a serverless function, but not both. This made it impossible to take advantage of the edge for parts of your app – if any route needed Node APIs, then you couldn’t deploy any of it to the edge. The same is true for other aspects of deployment configuration, such as regions and allocated memory: you had to choose one value that applied to every route in your entire app.
>>>>>>> sveltejs/main
SvelteKit はプラットフォームごとに固有の [adapter](/docs/kit/adapters) を使用してプロダクションへのデプロイ用にアプリのコードを変換しています。これまでは、デプロイメントの設定をアプリ全体レベルで行わなければなりませんでした。例えば、アプリを edge function としてデプロイするか、serverless function としてデプロイするか、どちらか一方は可能でしたが、両方同時に行うことはできませんでした。これでは、アプリの一部だけを edge にするというメリットを得ることができません – もし Node API を必要とするルート(route)がある場合、アプリ全体を edge にデプロイすることができないのです。リージョンの選択やメモリ割り当てなど、デプロイ設定の他の側面についても同様です: アプリ全体、すべてのルート(route)に適用される1つの値を選択しなければならなかったのです。

そしてこの度、`config` オブジェクトを `+server.js`、`+page(.server).js`、`+layout(.server).js` ファイルでエクスポートすることができるようになり、これらのルート(route)をどうやってデプロイするかコントロールできるようになりました。`+layout.js` でこれを行うと、そのすべての子ページに設定が適用されます。`config` の型は、デプロイ先の環境に依存するため、各 adapter ごとにユニークです。

Expand All @@ -187,11 +171,7 @@ export const config: Config = {
};
```

<<<<<<< HEAD
Config はトップレベルでマージされるため、レイアウトで設定された値をツリーのさらに下のページで上書きすることができます。詳細は[ドキュメント](https://kit.svelte.jp/docs/page-options#config)をご覧ください。
=======
Configs are merged at the top level, so you can override values set in a layout for pages further down the tree. For more details, see [the documentation](/docs/kit/page-options#config).
>>>>>>> sveltejs/main
Config はトップレベルでマージされるため、レイアウトで設定された値をツリーのさらに下のページで上書きすることができます。詳細は[ドキュメント](/docs/kit/page-options#config)をご覧ください。

Vercel にデプロイする場合、最新バージョンの SvelteKit と adapter をインストールすることでこの機能のメリットを享受することができます。ルートレベル(route-level)の config をサポートする adapter は SvelteKit 1.5 以降が必要であるため、adapter のバージョンを大幅にアップグレードする必要があるかもしれません。

Expand All @@ -200,19 +180,11 @@ npm i @sveltejs/kit@latest
npm i @sveltejs/adapter-auto@latest # or @sveltejs/adapter-vercel@latest
```

<<<<<<< HEAD
今現在は、[Vercel adapter](https://kit.svelte.jp/docs/adapter-vercel#deployment-configuration) のみがルート固有(route-specific)の config を実装していますが、他のプラットフォーム向けでもこれを実装するためのビルディングブロックがあります。もしあなたが adapter の作者なら、[この PR](https://github.com/sveltejs/kit/pull/8740) の変更点を参照し、要求事項を確認してください。

## Incremental static regeneration on Vercel

ルートレベル(Route-level)の config では、もう1つ要望の多かった機能も使えるようになりました – Vercel にデプロイされる SvelteKit アプリで、[incremental static regeneration](https://kit.svelte.jp/docs/adapter-vercel#incremental-static-regeneration) (ISR) が使用できるようになりました。ISR は、プリレンダリングされたコンテンツにおけるコストとパフォーマンスの優位性と、動的なレンダリングコンテンツの柔軟性の両方を提供します。
=======
For now, only the [Vercel adapter](/docs/kit/adapter-vercel#Deployment-configuration) implements route-specific config, but the building blocks are there to implement this for other platforms. If you’re an adapter author, see the changes in [the PR](https://github.com/sveltejs/kit/pull/8740) to see what is required.
今現在は、[Vercel adapter](/docs/kit/adapter-vercel#Deployment-configuration) のみがルート固有(route-specific)の config を実装していますが、他のプラットフォーム向けでもこれを実装するためのビルディングブロックがあります。もしあなたが adapter の作者なら、[この PR](https://github.com/sveltejs/kit/pull/8740) の変更点を参照し、要求事項を確認してください。

## Incremental static regeneration on Vercel

Route-level config also unlocked another much-requested feature – you can now use [incremental static regeneration](/docs/kit/adapter-vercel#Incremental-Static-Regeneration) (ISR) with SvelteKit apps deployed to Vercel. ISR provides the performance and cost advantages of prerendered content with the flexibility of dynamically rendered content.
>>>>>>> sveltejs/main
ルートレベル(Route-level)の config では、もう1つ要望の多かった機能も使えるようになりました – Vercel にデプロイされる SvelteKit アプリで、[incremental static regeneration](/docs/kit/adapter-vercel#Incremental-Static-Regeneration) (ISR) が使用できるようになりました。ISR は、プリレンダリングされたコンテンツにおけるコストとパフォーマンスの優位性と、動的なレンダリングコンテンツの柔軟性の両方を提供します。

ISR をルート(route)に追加するには、`config` オブジェクトに `isr` プロパティを追加します:

Expand All @@ -226,18 +198,10 @@ export const config = {

## And much more...

<<<<<<< HEAD
- [OPTIONS method](https://kit.svelte.jp/docs/routing#server) が `+server.js` ファイルでサポートされました。
- [OPTIONS method](/docs/kit/routing#server) が `+server.js` ファイルでサポートされました。
- [別のファイルに属するものをエクスポート](https://github.com/sveltejs/kit/pull/9055)したときや、+layout.svelte に[slot を置くのを忘れた](https://github.com/sveltejs/kit/pull/8475)ときのエラーメッセージが改善されました。
- [app.html でパブリックな環境変数にアクセス](https://kit.svelte.jp/docs/project-structure#project-files-src)できるようになりました
- レスポンスを作成する新たな [text ヘルパー](https://kit.svelte.jp/docs/modules#sveltejs-kit-text)が追加されました
- [app.html でパブリックな環境変数にアクセス](/docs/kit/project-structure#Project-files-src)できるようになりました
- レスポンスを作成する新たな [text ヘルパー](/docs/kit/@sveltejs-kit#text)が追加されました
- そしてたくさんのバグフィックス – リリースノートの全文については[changelog](https://github.com/sveltejs/kit/blob/master/packages/kit/CHANGELOG.md)をご覧ください。
=======
- The [OPTIONS method](/docs/kit/routing#server) is now supported in `+server.js` files
- Better error messages when you [export something that belongs in a different file](https://github.com/sveltejs/kit/pull/9055) or [forget to put a slot](https://github.com/sveltejs/kit/pull/8475) in your +layout.svelte.
- You can now [access public environment variables in app.html](/docs/kit/project-structure#Project-files-src)
- A new [text helper](/docs/kit/@sveltejs-kit#text) for creating responses
- And a ton of bug fixes – see [the changelog](https://github.com/sveltejs/kit/blob/master/packages/kit/CHANGELOG.md) for the full release notes.
>>>>>>> sveltejs/main

SvelteKit にコントリビュートしてくれた皆様、SvelteKit をプロジェクトで使ってくださっている皆様、ありがとうございます。以前にもお伝えしましたが、Svelte はコミュニティプロジェクトであり、皆様のフィードバックやコントリビューションがなくては成り立たないものです。
Loading
Loading