Files
protoc-frontend/vite.config.ts
2025-07-23 16:55:35 +03:00

28 lines
759 B
TypeScript

import react from '@vitejs/plugin-react-swc'
import path from 'path'
import { defineConfig } from 'vite'
// https://vitejs.dev/config/
export default defineConfig({
plugins: [react()],
resolve: {
alias: {
'@': path.resolve(__dirname, 'src'),
'@widgets': path.resolve('src/widgets'),
'@features': path.resolve('src/features'),
'@entities': path.resolve('src/entities'),
},
},
server: {
host: '0.0.0.0', // Открыть для всех IP адресов
port: 80, // Явно указать порт (по умолчанию 5173)
proxy: {
'/api': {
target: 'http://192.169.0.163:8000',
changeOrigin: true,
rewrite: path => path.replace(/^\/api/, ''),
},
},
},
})