Spaces:
Running
Running
| import { defineConfig, externalizeDepsPlugin } from 'electron-vite' | |
| import react from '@vitejs/plugin-react' | |
| import tailwindcss from '@tailwindcss/vite' | |
| import { resolve } from 'path' | |
| export default defineConfig({ | |
| main: { | |
| resolve: { | |
| alias: { | |
| '~': resolve(__dirname, '../src') | |
| } | |
| }, | |
| plugins: [externalizeDepsPlugin()], | |
| build: { | |
| rollupOptions: { | |
| input: { | |
| index: resolve(__dirname, 'electron/main.ts') | |
| } | |
| } | |
| } | |
| }, | |
| preload: { | |
| resolve: { | |
| alias: { | |
| '~': resolve(__dirname, '../src') | |
| } | |
| }, | |
| plugins: [externalizeDepsPlugin()], | |
| build: { | |
| rollupOptions: { | |
| input: { | |
| index: resolve(__dirname, 'electron/preload.ts') | |
| } | |
| } | |
| } | |
| }, | |
| renderer: { | |
| root: '.', | |
| build: { | |
| rollupOptions: { | |
| input: { | |
| index: resolve(__dirname, 'index.html') | |
| } | |
| } | |
| }, | |
| plugins: [ | |
| react(), | |
| tailwindcss() | |
| ] | |
| } | |
| }) | |