File tree 2 files changed +3
-2
lines changed
2 files changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -121,15 +121,15 @@ export async function build(cliOptions: Partial<ViteSSGOptions> = {}) {
121
121
await Promise . all (
122
122
routesPaths . map ( async ( route ) => {
123
123
try {
124
- const appCtx = await createApp ( false , route )
124
+ const appCtx = await createApp ( false , route ) as ViteSSGContext < true >
125
125
const { app, router, head, initialState } = appCtx
126
126
127
127
if ( router ) {
128
128
await router . push ( route )
129
129
await router . isReady ( )
130
130
}
131
131
132
- const transformedIndexHTML = ( await onBeforePageRender ?.( route , indexHTML , appCtx as ViteSSGContext < true > ) ) || indexHTML
132
+ const transformedIndexHTML = ( await onBeforePageRender ?.( route , indexHTML , appCtx ) ) || indexHTML
133
133
134
134
const ctx : SSRContext = { }
135
135
const appHTML = await renderToString ( app , ctx )
Original file line number Diff line number Diff line change
1
+ /* eslint-disable no-use-before-define */
1
2
import type { App } from 'vue'
2
3
import type { Router , RouteRecordRaw , RouterOptions as VueRouterOptions } from 'vue-router'
3
4
import type { HeadClient } from '@vueuse/head'
You can’t perform that action at this time.
0 commit comments