chuhai-payment-frontend/vite.config.ts
2024-05-19 17:43:52 +08:00

20 lines
468 B
TypeScript

import {defineConfig} from 'vite'
import react from '@vitejs/plugin-react'
import * as path from "path";
// https://vitejs.dev/config/
export default defineConfig(({mode}) => {
return {
plugins: [react()],
base: mode == 'test' ? './' : '/',
define: {
APP_DEFAULT_PATH: JSON.stringify('/')
},
resolve: {
alias: {
'@': path.resolve(__dirname, './src')
}
}
}
})