Fix import.meta.env error: use relative API URL
All checks were successful
Build and Push Frontend / build (push) Successful in 5s

The bundler doesn't process import.meta.env, use relative URL instead

Co-Authored-By: Claude Sonnet 4.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Hector Ros
2026-01-20 01:38:04 +01:00
parent 3fc9b01940
commit de0a0b8357

View File

@@ -1,9 +1,8 @@
import axios from 'axios'
// Determine API URL based on environment
const API_URL = import.meta.env.PROD
? 'https://api.fuq.tv/api'
: 'http://localhost:3000/api'
// In browser, we use relative URLs which will be proxied by the frontend server
const API_URL = '/api'
// Create axios instance with default config
export const apiClient = axios.create({