Skip to content

Commit c68d625

Browse files
committed
fix lint
1 parent 0e1b593 commit c68d625

File tree

4 files changed

+8
-8
lines changed

4 files changed

+8
-8
lines changed

packages/kit/src/exports/public.d.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -730,7 +730,7 @@ export interface LoadEvent<
730730
*
731731
* Setting the same header multiple times (even in separate `load` functions) is an error — you can only set a given header once.
732732
*
733-
* You cannot add a `set-cookie` header with `setHeaders` — use the [`cookies`](https://kit.svelte.dev/docs/types#public-types-cookies) API in a server-only `load` function instead.
733+
* You cannot add a `set-cookie` header with `setHeaders` — use the [`cookies`](https://kit.svelte.dev/docs/types#public-types-cookies) API in a server-only `load` function instead.
734734
*
735735
* `setHeaders` has no effect when a `load` function runs in the browser.
736736
*/
@@ -1030,7 +1030,7 @@ export interface RequestEvent<
10301030
*
10311031
* Setting the same header multiple times (even in separate `load` functions) is an error — you can only set a given header once.
10321032
*
1033-
* You cannot add a `set-cookie` header with `setHeaders` — use the [`cookies`](https://kit.svelte.dev/docs/types#public-types-cookies) API instead.
1033+
* You cannot add a `set-cookie` header with `setHeaders` — use the [`cookies`](https://kit.svelte.dev/docs/types#public-types-cookies) API instead.
10341034
*/
10351035
setHeaders(headers: Record<string, string>): void;
10361036
/**
@@ -1087,7 +1087,7 @@ export interface RouteDefinition<Config = any> {
10871087
methods: HttpMethod[];
10881088
};
10891089
page: {
1090-
methods: Extract<HttpMethod, 'GET' | 'POST'>[];
1090+
methods: Array<Extract<HttpMethod, 'GET' | 'POST'>>;
10911091
};
10921092
pattern: RegExp;
10931093
prerender: PrerenderOption;

packages/kit/src/runtime/app/navigation.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ export const beforeNavigate = /* @__PURE__ */ client_method('before_navigate');
109109
* If a function (or a Promise that resolves to a function) is returned from the callback, it will be called once the DOM has updated.
110110
*
111111
* `onNavigate` must be called during a component initialization. It remains active as long as the component is mounted.
112-
* @type {(callback: (navigation: import('@sveltejs/kit').OnNavigate) => MaybePromise<(() => void) | void>) => void}
112+
* @type {(callback: (navigation: import('@sveltejs/kit').OnNavigate) => import('../../types/internal.js').MaybePromise<(() => void) | void>) => void}
113113
* @param {(navigation: import('@sveltejs/kit').OnNavigate) => void} callback
114114
* @returns {void}
115115
*/

packages/kit/src/runtime/client/client.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1090,7 +1090,7 @@ export function create_client(app, target) {
10901090
const after_navigate = (
10911091
await Promise.all(
10921092
callbacks.on_navigate.map((fn) =>
1093-
fn(/** @type {import('types').OnNavigate} */ (nav.navigation))
1093+
fn(/** @type {import('@sveltejs/kit').OnNavigate} */ (nav.navigation))
10941094
)
10951095
)
10961096
).filter((value) => typeof value === 'function');
@@ -2021,7 +2021,7 @@ function reset_focus() {
20212021
* @param {import('./types').NavigationState} current
20222022
* @param {import('./types').NavigationIntent | undefined} intent
20232023
* @param {URL | null} url
2024-
* @param {import('types').NavigationType} type
2024+
* @param {import('@sveltejs/kit').NavigationType} type
20252025
*/
20262026
function create_navigation(current, intent, url, type) {
20272027
/** @type {(value: any) => void} */
@@ -2035,7 +2035,7 @@ function create_navigation(current, intent, url, type) {
20352035
reject = r;
20362036
});
20372037

2038-
/** @type {import('types').Navigation} */
2038+
/** @type {import('@sveltejs/kit').Navigation} */
20392039
const navigation = {
20402040
from: {
20412041
params: current.params,

packages/kit/src/types/internal.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -266,7 +266,7 @@ export interface ServerMetadataRoute {
266266
};
267267
methods: HttpMethod[];
268268
prerender: PrerenderOption | undefined;
269-
entries: Array<string> | undefined;
269+
entries: string[] | undefined;
270270
}
271271

272272
export interface ServerMetadata {

0 commit comments

Comments
 (0)