fix: 更新 Electron 配置,优化输入输出设置;精简多语言文件中的 ESLint 描述
This commit is contained in:
@@ -5,13 +5,15 @@ import path from 'path'
|
||||
|
||||
export default defineConfig({
|
||||
main: {
|
||||
entry: 'electron/main/index.ts',
|
||||
build: {
|
||||
target: 'node18',
|
||||
lib: {
|
||||
entry: 'electron/main/index.ts',
|
||||
},
|
||||
rollupOptions: {
|
||||
input: {
|
||||
index: path.resolve(__dirname, 'electron/main/index.ts'),
|
||||
},
|
||||
output: {
|
||||
format: 'cjs',
|
||||
},
|
||||
external: ['electron', 'electron-store'],
|
||||
},
|
||||
},
|
||||
@@ -22,11 +24,12 @@ export default defineConfig({
|
||||
},
|
||||
},
|
||||
preload: {
|
||||
entry: 'electron/preload/index.ts',
|
||||
build: {
|
||||
target: 'node18',
|
||||
rollupOptions: {
|
||||
input: path.resolve(__dirname, 'electron/preload/index.ts'),
|
||||
input: {
|
||||
index: path.resolve(__dirname, 'electron/preload/index.ts'),
|
||||
},
|
||||
output: {
|
||||
entryFileNames: '[name].js',
|
||||
format: 'cjs',
|
||||
|
||||
Reference in New Issue
Block a user