Skip to content

Commit aa7350b

Browse files
committed
more
1 parent 1b1ee83 commit aa7350b

File tree

15 files changed

+59
-54
lines changed

15 files changed

+59
-54
lines changed

apps/svelte.dev/content/docs/kit/98-reference/[email protected]

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ function text(
184184
## Action
185185

186186
Shape of a form action method that is part of `export const actions = {..}` in `+page.server.js`.
187-
See [form actions](https://svelte.dev/docs/kit/form-actions) for more information.
187+
See [form actions](/docs/kit/form-actions) for more information.
188188

189189
<div class="ts-block">
190190

@@ -275,7 +275,7 @@ type ActionResult<
275275
## Actions
276276

277277
Shape of the `export const actions = {..}` object in `+page.server.js`.
278-
See [form actions](https://svelte.dev/docs/kit/form-actions) for more information.
278+
See [form actions](/docs/kit/form-actions) for more information.
279279

280280
<div class="ts-block">
281281

@@ -296,7 +296,7 @@ type Actions<
296296

297297
## Adapter
298298

299-
[Adapters](https://svelte.dev/docs/kit/adapters) are responsible for taking the production build and turning it into something that can be deployed to a platform of your choosing.
299+
[Adapters](/docs/kit/adapters) are responsible for taking the production build and turning it into something that can be deployed to a platform of your choosing.
300300

301301
<div class="ts-block">
302302

@@ -384,7 +384,7 @@ during dev, build and prerendering
384384

385385
## AfterNavigate
386386

387-
The argument passed to [`afterNavigate`](https://svelte.dev/docs/kit/$app-navigation#afterNavigate) callbacks.
387+
The argument passed to [`afterNavigate`](/docs/kit/$app-navigation#afterNavigate) callbacks.
388388

389389
<div class="ts-block">
390390

@@ -443,7 +443,7 @@ type AwaitedActions<
443443

444444
## BeforeNavigate
445445

446-
The argument passed to [`beforeNavigate`](https://svelte.dev/docs/kit/$app-navigation#beforeNavigate) callbacks.
446+
The argument passed to [`beforeNavigate`](/docs/kit/$app-navigation#beforeNavigate) callbacks.
447447

448448
<div class="ts-block">
449449

@@ -955,8 +955,8 @@ and returns an `App.Platform` object
955955

956956
## Handle
957957

958-
The [`handle`](https://svelte.dev/docs/kit/hooks#Server-hooks-handle) hook runs every time the SvelteKit server receives a [request](https://svelte.dev/docs/kit/web-standards#Fetch-APIs-Request) and
959-
determines the [response](https://svelte.dev/docs/kit/web-standards#Fetch-APIs-Response).
958+
The [`handle`](/docs/kit/hooks#Server-hooks-handle) hook runs every time the SvelteKit server receives a [request](/docs/kit/web-standards#Fetch-APIs-Request) and
959+
determines the [response](/docs/kit/web-standards#Fetch-APIs-Response).
960960
It receives an `event` object representing the request and a function called `resolve`, which renders the route and generates a `Response`.
961961
This allows you to modify response headers or bodies, or bypass SvelteKit entirely (for implementing routes programmatically, for example).
962962

@@ -976,7 +976,7 @@ type Handle = (input: {
976976

977977
## HandleClientError
978978

979-
The client-side [`handleError`](https://svelte.dev/docs/kit/hooks#Shared-hooks-handleError) hook runs when an unexpected error is thrown while navigating.
979+
The client-side [`handleError`](/docs/kit/hooks#Shared-hooks-handleError) hook runs when an unexpected error is thrown while navigating.
980980

981981
If an unexpected error is thrown during loading or the following render, this function will be called with the error and the event.
982982
Make sure that this function _never_ throws an error.
@@ -996,7 +996,7 @@ type HandleClientError = (input: {
996996

997997
## HandleFetch
998998

999-
The [`handleFetch`](https://svelte.dev/docs/kit/hooks#Server-hooks-handleFetch) hook allows you to modify (or replace) a `fetch` request that happens inside a `load` function that runs on the server (or during pre-rendering)
999+
The [`handleFetch`](/docs/kit/hooks#Server-hooks-handleFetch) hook allows you to modify (or replace) a `fetch` request that happens inside a `load` function that runs on the server (or during pre-rendering)
10001000

10011001
<div class="ts-block">
10021002

@@ -1012,7 +1012,7 @@ type HandleFetch = (input: {
10121012

10131013
## HandleServerError
10141014

1015-
The server-side [`handleError`](https://svelte.dev/docs/kit/hooks#Shared-hooks-handleError) hook runs when an unexpected error is thrown while responding to a request.
1015+
The server-side [`handleError`](/docs/kit/hooks#Shared-hooks-handleError) hook runs when an unexpected error is thrown while responding to a request.
10161016

10171017
If an unexpected error is thrown during loading or rendering, this function will be called with the error and the event.
10181018
Make sure that this function _never_ throws an error.
@@ -1032,7 +1032,7 @@ type HandleServerError = (input: {
10321032

10331033
## HttpError
10341034

1035-
The object returned by the [`error`](https://svelte.dev/docs/kit/@sveltejs-kit#error) function.
1035+
The object returned by the [`error`](/docs/kit/@sveltejs-kit#error) function.
10361036

10371037
<div class="ts-block">
10381038

@@ -1087,7 +1087,7 @@ type LessThan<
10871087

10881088
## Load
10891089

1090-
The generic form of `PageLoad` and `LayoutLoad`. You should import those from `./$types` (see [generated types](https://svelte.dev/docs/kit/types#Generated-types))
1090+
The generic form of `PageLoad` and `LayoutLoad`. You should import those from `./$types` (see [generated types](/docs/kit/types#Generated-types))
10911091
rather than using `Load` directly.
10921092

10931093
<div class="ts-block">
@@ -1119,7 +1119,7 @@ type Load<
11191119

11201120
## LoadEvent
11211121

1122-
The generic form of `PageLoadEvent` and `LayoutLoadEvent`. You should import those from `./$types` (see [generated types](https://svelte.dev/docs/kit/types#Generated-types))
1122+
The generic form of `PageLoadEvent` and `LayoutLoadEvent`. You should import those from `./$types` (see [generated types](/docs/kit/types#Generated-types))
11231123
rather than using `LoadEvent` directly.
11241124

11251125
<div class="ts-block">
@@ -1559,7 +1559,7 @@ type NumericRange<
15591559

15601560
## OnNavigate
15611561

1562-
The argument passed to [`onNavigate`](https://svelte.dev/docs/kit/$app-navigation#onNavigate) callbacks.
1562+
The argument passed to [`onNavigate`](/docs/kit/$app-navigation#onNavigate) callbacks.
15631563

15641564
<div class="ts-block">
15651565

@@ -1732,7 +1732,7 @@ Filled only after a form submission. See [form actions](https://svelte.dev/docs/
17321732

17331733
## ParamMatcher
17341734

1735-
The shape of a param matcher. See [matching](https://svelte.dev/docs/kit/advanced-routing#Matching) for more info.
1735+
The shape of a param matcher. See [matching](/docs/kit/advanced-routing#Matching) for more info.
17361736

17371737
<div class="ts-block">
17381738

@@ -1754,7 +1754,7 @@ type PrerenderOption = boolean | 'auto';
17541754

17551755
## Redirect
17561756

1757-
The object returned by the [`redirect`](https://svelte.dev/docs/kit/@sveltejs-kit#redirect) function
1757+
The object returned by the [`redirect`](/docs/kit/@sveltejs-kit#redirect) function
17581758

17591759
<div class="ts-block">
17601760

@@ -2003,7 +2003,7 @@ isSubRequest: boolean;
20032003

20042004
A `(event: RequestEvent) => Response` function exported from a `+server.js` file that corresponds to an HTTP verb (`GET`, `PUT`, `PATCH`, etc) and handles requests with that method.
20052005

2006-
It receives `Params` as the first generic argument, which you can skip by using [generated types](https://svelte.dev/docs/kit/types#Generated-types) instead.
2006+
It receives `Params` as the first generic argument, which you can skip by using [generated types](/docs/kit/types#Generated-types) instead.
20072007

20082008
<div class="ts-block">
20092009

@@ -2022,7 +2022,7 @@ type RequestHandler<
20222022

20232023
## Reroute
20242024

2025-
The [`reroute`](https://svelte.dev/docs/kit/hooks#Universal-hooks-reroute) hook allows you to modify the URL before it is used to determine which route to render.
2025+
The [`reroute`](/docs/kit/hooks#Universal-hooks-reroute) hook allows you to modify the URL before it is used to determine which route to render.
20262026

20272027
<div class="ts-block">
20282028

@@ -2359,7 +2359,7 @@ A function that turns an asset filename into a `ReadableStream`. Required for th
23592359

23602360
## ServerLoad
23612361

2362-
The generic form of `PageServerLoad` and `LayoutServerLoad`. You should import those from `./$types` (see [generated types](https://svelte.dev/docs/kit/types#Generated-types))
2362+
The generic form of `PageServerLoad` and `LayoutServerLoad`. You should import those from `./$types` (see [generated types](/docs/kit/types#Generated-types))
23632363
rather than using `ServerLoad` directly.
23642364

23652365
<div class="ts-block">

apps/svelte.dev/content/docs/kit/98-reference/20-$app-navigation.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ function preloadData(href: string): Promise<
227227

228228
## pushState
229229

230-
Programmatically create a new history entry with the given `$page.state`. To use the current URL, you can pass `''` as the first argument. Used for [shallow routing](https://svelte.dev/docs/kit/shallow-routing).
230+
Programmatically create a new history entry with the given `$page.state`. To use the current URL, you can pass `''` as the first argument. Used for [shallow routing](/docs/kit/shallow-routing).
231231

232232
<div class="ts-block">
233233

@@ -244,7 +244,7 @@ function pushState(
244244

245245
## replaceState
246246

247-
Programmatically replace the current history entry with the given `$page.state`. To use the current URL, you can pass `''` as the first argument. Used for [shallow routing](https://svelte.dev/docs/kit/shallow-routing).
247+
Programmatically replace the current history entry with the given `$page.state`. To use the current URL, you can pass `''` as the first argument. Used for [shallow routing](/docs/kit/shallow-routing).
248248

249249
<div class="ts-block">
250250

apps/svelte.dev/content/docs/kit/98-reference/20-$app-paths.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ import { assets, base, resolveRoute } from '$app/paths';
1111

1212
## assets
1313

14-
An absolute path that matches [`config.kit.paths.assets`](https://svelte.dev/docs/kit/configuration#paths).
14+
An absolute path that matches [`config.kit.paths.assets`](/docs/kit/configuration#paths).
1515

1616
> [!NOTE] If a value for `config.kit.paths.assets` is specified, it will be replaced with `'/_svelte_kit_assets'` during `vite dev` or `vite preview`, since the assets don't yet live at their eventual URL.
1717
@@ -31,7 +31,7 @@ let assets:
3131

3232
## base
3333

34-
A string that matches [`config.kit.paths.base`](https://svelte.dev/docs/kit/configuration#paths).
34+
A string that matches [`config.kit.paths.base`](/docs/kit/configuration#paths).
3535

3636
Example usage: `<a href="{base}/your-page">Link</a>`
3737

apps/svelte.dev/content/docs/kit/98-reference/20-$app-stores.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ const page: import('svelte/store').Readable<
6767

6868
## updated
6969

70-
A readable store whose initial value is `false`. If [`version.pollInterval`](https://svelte.dev/docs/kit/configuration#version) is a non-zero value, SvelteKit will poll for new versions of the app and update the store value to `true` when it detects one. `updated.check()` will force an immediate check, regardless of polling.
70+
A readable store whose initial value is `false`. If [`version.pollInterval`](/docs/kit/configuration#version) is a non-zero value, SvelteKit will poll for new versions of the app and update the store value to `true` when it detects one. `updated.check()` will force an immediate check, regardless of polling.
7171

7272
On the server, this store can only be subscribed to during component initialization. In the browser, it can be subscribed to at any time.
7373

apps/svelte.dev/content/docs/kit/98-reference/27-$service-worker.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ const build: string[];
4343

4444
## files
4545

46-
An array of URL strings representing the files in your static directory, or whatever directory is specified by `config.kit.files.assets`. You can customize which files are included from `static` directory using [`config.kit.serviceWorker.files`](https://svelte.dev/docs/kit/configuration)
46+
An array of URL strings representing the files in your static directory, or whatever directory is specified by `config.kit.files.assets`. You can customize which files are included from `static` directory using [`config.kit.serviceWorker.files`](/docs/kit/configuration)
4747

4848
<div class="ts-block">
4949

@@ -72,7 +72,7 @@ const prerendered: string[];
7272

7373
## version
7474

75-
See [`config.kit.version`](https://svelte.dev/docs/kit/configuration#version). It's useful for generating unique cache names inside your service worker, so that a later deployment of your app can invalidate old caches.
75+
See [`config.kit.version`](/docs/kit/configuration#version). It's useful for generating unique cache names inside your service worker, so that a later deployment of your app can invalidate old caches.
7676

7777
<div class="ts-block">
7878

apps/svelte.dev/content/docs/kit/98-reference/54-types.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ message: string;
175175

176176
## Locals
177177

178-
The interface that defines `event.locals`, which can be accessed in server [hooks](https://svelte.dev/docs/kit/hooks) (`handle`, and `handleError`), server-only `load` functions, and `+server.js` files.
178+
The interface that defines `event.locals`, which can be accessed in server [hooks](/docs/kit/hooks) (`handle`, and `handleError`), server-only `load` functions, and `+server.js` files.
179179

180180
<div class="ts-block">
181181

@@ -187,7 +187,7 @@ interface Locals {}
187187

188188
## PageData
189189

190-
Defines the common shape of the [$page.data store](https://svelte.dev/docs/kit/$app-stores#page) - that is, the data that is shared between all pages.
190+
Defines the common shape of the [$page.data store](/docs/kit/$app-stores#page) - that is, the data that is shared between all pages.
191191
The `Load` and `ServerLoad` functions in `./$types` will be narrowed accordingly.
192192
Use optional properties for data that is only present on specific pages. Do not add an index signature (`[key: string]: any`).
193193

@@ -201,7 +201,7 @@ interface PageData {}
201201

202202
## PageState
203203

204-
The shape of the `$page.state` object, which can be manipulated using the [`pushState`](https://svelte.dev/docs/kit/$app-navigation#pushState) and [`replaceState`](https://svelte.dev/docs/kit/$app-navigation#replaceState) functions from `$app/navigation`.
204+
The shape of the `$page.state` object, which can be manipulated using the [`pushState`](/docs/kit/$app-navigation#pushState) and [`replaceState`](/docs/kit/$app-navigation#replaceState) functions from `$app/navigation`.
205205

206206
<div class="ts-block">
207207

@@ -213,7 +213,7 @@ interface PageState {}
213213

214214
## Platform
215215

216-
If your adapter provides [platform-specific context](https://svelte.dev/docs/kit/adapters#Platform-specific-context) via `event.platform`, you can specify it here.
216+
If your adapter provides [platform-specific context](/docs/kit/adapters#Platform-specific-context) via `event.platform`, you can specify it here.
217217

218218
<div class="ts-block">
219219

apps/svelte.dev/content/docs/svelte/98-reference/20-svelte.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ Use callback props and/or the `$host()` rune instead — see https://svelte.dev/
8282

8383
</blockquote>
8484

85-
Creates an event dispatcher that can be used to dispatch [component events](https://svelte.dev/docs/svelte/legacy-on#Component-events).
85+
Creates an event dispatcher that can be used to dispatch [component events](/docs/svelte/legacy-on#Component-events).
8686
Event dispatchers are functions that can take two arguments: `name` and `detail`.
8787

8888
Component events created with `createEventDispatcher` create a
@@ -279,7 +279,7 @@ it can be called from an external module).
279279

280280
If a function is returned _synchronously_ from `onMount`, it will be called when the component is unmounted.
281281

282-
`onMount` does not run inside [server-side components](https://svelte.dev/docs/svelte/svelte-server#render).
282+
`onMount` does not run inside [server-side components](/docs/svelte/svelte-server#render).
283283

284284
<div class="ts-block">
285285

@@ -344,7 +344,7 @@ function unmount(component: Record<string, any>): void;
344344

345345
## untrack
346346

347-
When used inside a [`$derived`](https://svelte.dev/docs/svelte/$derived) or [`$effect`](https://svelte.dev/docs/svelte/$effect),
347+
When used inside a [`$derived`](/docs/svelte/$derived) or [`$effect`](/docs/svelte/$effect),
348348
any state read inside `fn` will not be treated as a dependency.
349349

350350
```ts
@@ -733,7 +733,7 @@ let { banner }: { banner: Snippet<[{ text: string }]> } = $props();
733733
```
734734
You can only call a snippet through the `{@render ...}` tag.
735735

736-
https://svelte.dev/docs/svelte/snippet
736+
/docs/svelte/snippet
737737

738738
<div class="ts-block">
739739

@@ -763,7 +763,7 @@ interface Snippet<Parameters extends unknown[] = []> {/*…*/}
763763
This was the base class for Svelte components in Svelte 4. Svelte 5+ components
764764
are completely different under the hood. For typing, use `Component` instead.
765765
To instantiate components, use `mount` instead`.
766-
See [migration guide](https://svelte.dev/docs/svelte/v5-migration-guide#Components-are-no-longer-classes) for more info.
766+
See [migration guide](/docs/svelte/v5-migration-guide#Components-are-no-longer-classes) for more info.
767767

768768
<div class="ts-block">
769769

apps/svelte.dev/content/docs/svelte/98-reference/21-svelte-compiler.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ import {
2121

2222
The current version, as set in package.json.
2323

24-
https://svelte.dev/docs/svelte-compiler#svelte-version
24+
/docs/svelte-compiler#svelte-version
2525

2626
<div class="ts-block">
2727

apps/svelte.dev/content/docs/svelte/98-reference/21-svelte-transition.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ function blur(
4242

4343
## crossfade
4444

45-
The `crossfade` function creates a pair of [transitions](https://svelte.dev/docs/svelte/transition) called `send` and `receive`. When an element is 'sent', it looks for a corresponding element being 'received', and generates a transition that transforms the element to its counterpart's position and fades it out. When an element is 'received', the reverse happens. If there is no counterpart, the `fallback` transition is used.
45+
The `crossfade` function creates a pair of [transitions](/docs/svelte/transition) called `send` and `receive`. When an element is 'sent', it looks for a corresponding element being 'received', and generates a transition that transforms the element to its counterpart's position and fades it out. When an element is 'received', the reverse happens. If there is no counterpart, the `fallback` transition is used.
4646

4747
<div class="ts-block">
4848

apps/svelte.dev/scripts/sync-docs/index.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import { strip_origin } from '@sveltejs/site-kit/markdown';
12
import { preprocess } from '@sveltejs/site-kit/markdown/preprocess';
23
import path from 'node:path';
34
import fs from 'node:fs';
@@ -6,7 +7,7 @@ import ts from 'typescript';
67
import glob from 'tiny-glob/sync';
78
import chokidar from 'chokidar';
89
import { fileURLToPath } from 'node:url';
9-
import { clone_repo, migrate_meta_json, strip_origin } from './utils';
10+
import { clone_repo, migrate_meta_json } from './utils';
1011
import { get_types, read_d_ts_file, read_types } from './types';
1112
import type { Modules } from '@sveltejs/site-kit/markdown';
1213

0 commit comments

Comments
 (0)