-
Notifications
You must be signed in to change notification settings - Fork 16
Expand file tree
/
Copy pathvite.wizard.config.ts
More file actions
35 lines (33 loc) · 900 Bytes
/
vite.wizard.config.ts
File metadata and controls
35 lines (33 loc) · 900 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
import { defineConfig } from 'vite'
import react from '@vitejs/plugin-react'
import path from 'path'
import { fileURLToPath } from 'url'
const __dirname = path.dirname(fileURLToPath(import.meta.url))
export default defineConfig({
plugins: [react()],
root: path.resolve(__dirname, 'electron/setup-wizard'),
base: './', // relative paths for file:// protocol in production
build: {
outDir: path.resolve(__dirname, 'dist/wizard'),
emptyOutDir: true,
sourcemap: true,
},
server: {
port: 5174, // separate from main app's 5173
},
resolve: {
alias: {
'@electron': path.resolve(__dirname, './electron'),
},
},
css: {
postcss: {
plugins: [
(await import('tailwindcss')).default({
config: path.resolve(__dirname, 'tailwind.config.wizard.js'),
}),
(await import('autoprefixer')).default,
],
},
},
})