@@ -2,6 +2,11 @@ export type { Config }
2
2
export type { ConfigNameBuiltIn }
3
3
export type { ConfigMeta }
4
4
export type { HookName }
5
+ export type { ConfigVikePackages }
6
+ export type { ConfigVikeReact }
7
+ export type { ConfigVikeVue }
8
+ export type { ConfigVikeSolid }
9
+ export type { ConfigVikeSvelte }
5
10
6
11
import type { PrefetchStaticAssets } from '../../client/client-routing-runtime/prefetch/getPrefetchSettings.js'
7
12
import { ConfigDefinition } from '../../node/plugin/plugins/importUserCode/v1-design/getVikeConfig/configDefinitionsBuiltIn.js'
@@ -33,7 +38,7 @@ type ConfigNameBuiltIn = ConfigNameBuiltInPublic | ConfigNameBuiltInInternal
33
38
*
34
39
* https://vite-plugin-ssr.com/config
35
40
*/
36
- type Config < Page = unknown > = {
41
+ type Config < Page = unknown > = ConfigVikePackagesAll & {
37
42
Page ?: Page
38
43
39
44
/** The page's URL(s).
@@ -158,6 +163,14 @@ type Config<Page = unknown> = {
158
163
prefetchStaticAssets ?: PrefetchStaticAssets | ImportString
159
164
}
160
165
166
+ type ConfigVikePackagesAll = ConfigVikePackages & ( ConfigVikeReact | ConfigVikeVue | ConfigVikeSolid | ConfigVikeSvelte )
167
+ interface ConfigVikePackages { } // For vike-* packages that don't conflict, e.g. the `isr` config of vike-vercel
168
+ // Because of conflicts, e.g. the Page config, we need a different interface for each vike-{react/vue/solid/svelte}
169
+ interface ConfigVikeReact { } // For vike-react
170
+ interface ConfigVikeVue { } // For vike-vue
171
+ interface ConfigVikeSolid { } // For vike-solid
172
+ interface ConfigVikeSvelte { } // For vike-svelte (doesn't exist yet)
173
+
161
174
type ConfigMeta = Record < string , ConfigDefinition >
162
175
163
176
type ImportString = `import:${string } `
0 commit comments