prefer same-origin api proxy
CI / compose (push) Successful in 10m28s

This commit is contained in:
Marco0300
2026-09-03 16:54:27 +02:00
parent 462d0719d0
commit 56229c7ef1
2 changed files with 3 additions and 3 deletions
+2 -2
View File
@@ -1,8 +1,8 @@
/* ProspectOS frontend MVP. Configure before loading with window.API_BASE = 'http://127.0.0.1:8000'; */
/* ProspectOS frontend. Set window.__PROSPECT_CONFIG__.apiBase to an explicit API origin only when the UI is not served through the same-host /api proxy. */
(() => {
'use strict';
const publicConfig = window.__PROSPECT_CONFIG__ || {};
const API_BASE = (publicConfig.apiBase || window.API_BASE || localStorage.getItem('prospect_api_base') || '').replace(/\/$/, '');
const API_BASE = (publicConfig.apiBase ?? window.API_BASE ?? '').replace(/\/$/, '');
const endpoint = (path) => `${API_BASE}${path}`;
let prospects = [], selectedId = null, selectedDetail = null, currentUser = null;
let page = 1, pageSize = 10, hasNextPage = false, savedFilters = [], reviewQueue = [], selectedReviewIds = new Set();