fix(vite-node): wrong entry been resolved in stub mode (#3983)

This commit is contained in:
Anthony Fu 2022-03-31 15:11:50 +08:00 committed by GitHub
parent 281784d238
commit 9c2e208090
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -50,6 +50,9 @@ async function writeManifest () {
let render
export default async (ssrContext) => {
// Workaround for stub mode
// https://github.com/nuxt/framework/pull/3983
process.server = true
render = render || (await runner.executeFile(entry)).default
const result = await render(ssrContext)
await writeManifest()