File size: 695 Bytes
9d3c32a
 
 
 
 
 
 
 
 
 
9a9d18a
 
743ae7d
9d3c32a
 
 
9a9d18a
 
 
9d3c32a
 
 
 
 
 
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
import { defineConfig } from "vite";
import react from "@vitejs/plugin-react-swc";
import path from "path";
import { componentTagger } from "lovable-tagger";

// https://vitejs.dev/config/
export default defineConfig(({ mode }) => ({
  server: {
    host: "::",
    port: 8080,
    // Proxy removed - the React app now handles API URLs directly through the ApiContext
    // This provides full flexibility for localhost/ngrok switching at runtime
  },
  plugins: [react(), mode === "development" && componentTagger()].filter(
    Boolean
  ),
  preview: {
    allowedHosts: ["jurmy24-lelab.hf.space"],
  },
  resolve: {
    alias: {
      "@": path.resolve(__dirname, "./src"),
    },
  },
}));