File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ # Frontend Environment Variables
2+ # Copy this to .env.local for local development overrides
3+
4+ # Backend API URL
5+ # Production: Set in Vercel dashboard (e.g., https://codeintel-backend.railway.app)
6+ # Development: Defaults to http://localhost:8000 (Docker Compose)
7+ VITE_API_URL = http://localhost:8000
8+
9+ # Supabase Configuration
10+ # Get these from your Supabase project settings
11+ VITE_SUPABASE_URL = https://your-project.supabase.co
12+ VITE_SUPABASE_ANON_KEY = your-anon-key-here
Original file line number Diff line number Diff line change @@ -12,8 +12,7 @@ import { ImpactAnalyzer } from './ImpactAnalyzer'
1212import { PerformanceDashboard } from './PerformanceDashboard'
1313import { UserNav } from './UserNav'
1414import type { Repository } from '../types'
15-
16- const API_URL = 'http://localhost:8000'
15+ import { API_URL } from '../config/api'
1716
1817type RepoTab = 'overview' | 'search' | 'dependencies' | 'insights' | 'impact'
1918
Original file line number Diff line number Diff line change 1+ /**
2+ * API Configuration
3+ *
4+ * Centralizes API URL configuration for all frontend components.
5+ *
6+ * - Production: Set VITE_API_URL in Vercel dashboard to Railway backend URL
7+ * - Development: Defaults to localhost:8000 (Docker Compose)
8+ * - Local dev without Docker: Can override with .env.local
9+ */
10+
11+ const API_URL = import . meta. env . VITE_API_URL || 'http://localhost:8000'
12+
13+ export { API_URL }
You can’t perform that action at this time.
0 commit comments