mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-26 15:42:09 +00:00
fix(vite): respect users config (#2395)
Co-authored-by: Daniel Roe <daniel@roe.dev>
This commit is contained in:
parent
d91677e72f
commit
737f1bf80c
@ -21,7 +21,6 @@ async function bundle (nuxt: Nuxt, builder: any) {
|
|||||||
nuxt,
|
nuxt,
|
||||||
builder,
|
builder,
|
||||||
config: vite.mergeConfig(
|
config: vite.mergeConfig(
|
||||||
nuxt.options.vite || {},
|
|
||||||
{
|
{
|
||||||
root: nuxt.options.rootDir,
|
root: nuxt.options.rootDir,
|
||||||
mode: nuxt.options.dev ? 'development' : 'production',
|
mode: nuxt.options.dev ? 'development' : 'production',
|
||||||
@ -79,7 +78,8 @@ async function bundle (nuxt: Nuxt, builder: any) {
|
|||||||
jsxPlugin(),
|
jsxPlugin(),
|
||||||
defaultExportPlugin()
|
defaultExportPlugin()
|
||||||
]
|
]
|
||||||
} as ViteOptions
|
} as ViteOptions,
|
||||||
|
nuxt.options.vite || {}
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -25,7 +25,6 @@ export async function bundle (nuxt: Nuxt) {
|
|||||||
const ctx: ViteBuildContext = {
|
const ctx: ViteBuildContext = {
|
||||||
nuxt,
|
nuxt,
|
||||||
config: vite.mergeConfig(
|
config: vite.mergeConfig(
|
||||||
nuxt.options.vite as any || {},
|
|
||||||
{
|
{
|
||||||
root: nuxt.options.srcDir,
|
root: nuxt.options.srcDir,
|
||||||
mode: nuxt.options.dev ? 'development' : 'production',
|
mode: nuxt.options.dev ? 'development' : 'production',
|
||||||
@ -93,7 +92,8 @@ export async function bundle (nuxt: Nuxt) {
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} as ViteOptions
|
} as ViteOptions,
|
||||||
|
nuxt.options.vite as any || {}
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user