mirror of
https://github.com/electron-vite/electron-vite-vue
synced 2025-02-26 04:40:10 +08:00
fix: configure build options
This commit is contained in:
parent
e2798e025d
commit
f41ddead18
@ -12,12 +12,23 @@ export default defineConfig({
|
||||
electron({
|
||||
main: {
|
||||
entry: 'electron-main/index.ts',
|
||||
vite: {
|
||||
build: {
|
||||
sourcemap: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
preload: {
|
||||
input: {
|
||||
// You can configure multiple preload here
|
||||
p1: join(__dirname, 'electron-preload'),
|
||||
splash: join(__dirname, 'electron-preload/splash.ts'),
|
||||
},
|
||||
vite: {
|
||||
build: {
|
||||
// For debug
|
||||
sourcemap: 'inline',
|
||||
}
|
||||
}
|
||||
},
|
||||
}),
|
||||
// Enable use Electron, Node.js API in Renderer-process
|
||||
@ -25,4 +36,8 @@ export default defineConfig({
|
||||
// TODO: integrate into 'vite-plugin-electron' by default
|
||||
polyfillExports(),
|
||||
],
|
||||
build: {
|
||||
// TODO: integrate into 'vite-plugin-electron' by default
|
||||
emptyOutDir: false,
|
||||
},
|
||||
})
|
||||
|
Loading…
x
Reference in New Issue
Block a user