21 lines
439 B
TypeScript
21 lines
439 B
TypeScript
import {defineConfig, loadEnv} from 'vite'
|
|
import react from '@vitejs/plugin-react-swc'
|
|
|
|
// https://vitejs.dev/config/
|
|
export default defineConfig(({mode}) => {
|
|
const { VITE_CONTEXT_PATH } = loadEnv(mode, process.cwd());
|
|
|
|
return {
|
|
base: VITE_CONTEXT_PATH,
|
|
plugins: [react()],
|
|
build: {
|
|
rollupOptions: {
|
|
input: {
|
|
main: 'index.html',
|
|
receiver: 'receiver.html',
|
|
}
|
|
}
|
|
}
|
|
}
|
|
})
|