mirror of
https://github.com/alex8088/electron-vite.git
synced 2026-09-04 15:22:44 +08:00
fix(swcPlugin): also disable oxc on Vite 8 (#920)
Vite 8 defaults transform to Oxc; esbuild:false alone is ignored and warns. SWC should disable both. Fixes #916. Co-authored-by: edenbuilds <279970382+edenbuilds@users.noreply.github.com> Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
parent
31965d2972
commit
608461c04c
@ -83,8 +83,12 @@ export function swcPlugin(options: SwcOptions = {}): Plugin {
|
||||
return {
|
||||
name: 'vite:swc',
|
||||
config(): UserConfig {
|
||||
// Vite 8 defaults to Oxc for transform; `esbuild: false` is ignored and
|
||||
// warns. SWC replaces both paths when this plugin is active.
|
||||
// See https://github.com/alex8088/electron-vite/issues/916
|
||||
return {
|
||||
esbuild: false
|
||||
esbuild: false,
|
||||
oxc: false
|
||||
}
|
||||
},
|
||||
async configResolved(resolvedConfig): Promise<void> {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user