mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-11 08:33:53 +00:00
parent
f718a33548
commit
c8f8691496
@ -50,7 +50,14 @@ export async function buildServer (ctx: ViteBuildContext) {
|
||||
},
|
||||
plugins: [
|
||||
cacheDirPlugin(ctx.nuxt.options.rootDir, 'server'),
|
||||
vuePlugin(),
|
||||
vuePlugin({
|
||||
// workaround for https://github.com/vuejs/vue-next/issues/4666
|
||||
template: {
|
||||
compilerOptions: {
|
||||
ssrRuntimeModuleName: 'vue/server-renderer/index.mjs'
|
||||
}
|
||||
}
|
||||
}),
|
||||
transformNuxtSetup()
|
||||
]
|
||||
} as ViteOptions)
|
||||
|
@ -14,7 +14,13 @@ export function vue (ctx: WebpackConfigContext) {
|
||||
config.module.rules.push({
|
||||
test: /\.vue$/i,
|
||||
loader: 'vue-loader',
|
||||
options: options.build.loaders.vue
|
||||
options: {
|
||||
// workaround for https://github.com/vuejs/vue-next/issues/4666
|
||||
compilerOptions: {
|
||||
ssrRuntimeModuleName: 'vue/server-renderer/index.mjs'
|
||||
},
|
||||
...options.build.loaders.vue
|
||||
}
|
||||
})
|
||||
|
||||
if (ctx.isClient) {
|
||||
|
Loading…
Reference in New Issue
Block a user