You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: remove internal __sveltekit/ module declarations from types (#11620)
* fix: remove internal `__sveltekit/` module declarations from types
Takes advantage of the fact that dts-buddy doesn't detect the ambient-private.d.ts module declarations (which arguably is a bit weird and could result in buggy behavior, but we can use it to our advantage here).
fixes#11607
* lint
* re-export values from internal modules
* move files
* point dts-buddy at facade .d.ts files
* remove some junk we no longer need
---------
Co-authored-by: Rich Harris <[email protected]>
// dts-buddy doesn't inline imports of module declaration in ambient-private.d.ts but also doesn't include them, resulting in broken types - guard against that
* A string that matches [`config.kit.paths.base`](https://kit.svelte.dev/docs/configuration#paths).
3
+
*
4
+
* Example usage: `<a href="{base}/your-page">Link</a>`
5
+
*/
6
+
exportletbase: ''| `/${string}`;
7
+
8
+
/**
9
+
* An absolute path that matches [`config.kit.paths.assets`](https://kit.svelte.dev/docs/configuration#paths).
10
+
*
11
+
* > 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.
* SvelteKit analyses your app during the `build` step by running it. During this process, `building` is `true`. This also applies during prerendering.
87
-
*/
88
-
exportconstbuilding: boolean;
89
-
/**
90
-
* True during prerendering, false otherwise.
91
-
*/
92
-
exportconstprerendering: boolean;
93
-
/**
94
-
* The value of `config.kit.version.name`.
95
-
*/
96
-
exportconstversion: string;
97
-
exportfunctionset_building(): void;
98
-
exportfunctionset_prerendering(): void;
99
-
}
100
-
101
-
/** Internal version of $app/paths */
102
-
declare module '__sveltekit/paths'{
103
-
/**
104
-
* A string that matches [`config.kit.paths.base`](https://kit.svelte.dev/docs/configuration#paths).
105
-
*
106
-
* Example usage: `<a href="{base}/your-page">Link</a>`
107
-
*/
108
-
exportletbase: ''| `/${string}`;
109
-
/**
110
-
* An absolute path that matches [`config.kit.paths.assets`](https://kit.svelte.dev/docs/configuration#paths).
111
-
*
112
-
* > 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.
* A string that matches [`config.kit.paths.base`](https://kit.svelte.dev/docs/configuration#paths).
2082
+
*
2083
+
* Example usage: `<a href="{base}/your-page">Link</a>`
2084
+
*/
2085
+
exportletbase: ''| `/${string}`;
2086
+
2087
+
/**
2088
+
* An absolute path that matches [`config.kit.paths.assets`](https://kit.svelte.dev/docs/configuration#paths).
2089
+
*
2090
+
* > 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.
* SvelteKit analyses your app during the `build` step by running it. During this process, `building` is `true`. This also applies during prerendering.
2205
-
*/
2206
-
export const building: boolean;
2207
-
/**
2208
-
* True during prerendering, false otherwise.
2209
-
*/
2210
-
export const prerendering: boolean;
2211
-
/**
2212
-
* The value of `config.kit.version.name`.
2213
-
*/
2214
-
export const version: string;
2215
-
export function set_building(): void;
2216
-
export function set_prerendering(): void;
2217
-
}
2218
-
2219
-
/** Internal version of $app/paths */
2220
-
declare module '__sveltekit/paths' {
2221
-
/**
2222
-
* A string that matches [`config.kit.paths.base`](https://kit.svelte.dev/docs/configuration#paths).
2223
-
*
2224
-
* Example usage: `<ahref="{base}/your-page">Link</a>`
2225
-
*/
2226
-
exportletbase: ''| `/${string}`;
2227
-
/**
2228
-
* An absolute path that matches [`config.kit.paths.assets`](https://kit.svelte.dev/docs/configuration#paths).
2229
-
*
2230
-
* > 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.
0 commit comments