import { defineConfig } from 'vite' import react from '@vitejs/plugin-react' import tailwindcss from '@tailwindcss/vite' // https://vite.dev/config/ export default defineConfig({ plugins: [react(), tailwindcss()], server: { host: '0.0.0.0', port: 5173, watch: { usePolling: true, }, hmr: { clientPort: 5173, }, proxy: { '/api': { target: 'http://backend:3000', changeOrigin: true, }, '/socket.io': { target: 'http://backend:3000', changeOrigin: true, ws: true, } } }, preview: { host: '0.0.0.0', port: 5173, }, build: { minify: 'terser', terserOptions: { compress: { drop_console: true, // Remove all console statements in production drop_debugger: true, // Remove debugger statements pure_funcs: ['console.log', 'console.warn', 'console.debug'] // Specifically target these } } } })