Merge branch 'feat/environment-variables' into 'main'
Introduce backend URL environment variable See merge request ics/sp/2025/n25b/pepperplus-ui!53
This commit was merged in pull request #53.
This commit is contained in:
@@ -5,6 +5,7 @@ import {useCallback, useEffect, useRef, useState} from "react";
|
||||
|
||||
import {applyPriorityPredicates, type PriorityFilterPredicate} from "../../utils/priorityFiltering.ts";
|
||||
import {cell, type Cell} from "../../utils/cellStore.ts";
|
||||
import { API_BASE_URL } from "../../config/api.ts";
|
||||
|
||||
type ExtraLevelName = 'LLM' | 'OBSERVATION' | 'ACTION' | 'CHAT';
|
||||
|
||||
@@ -210,7 +211,7 @@ export function useLogs(filterPredicates: Map<string, LogFilterPredicate>) {
|
||||
// Only create one SSE connection for the lifetime of the hook.
|
||||
if (sseRef.current) return;
|
||||
|
||||
const es = new EventSource("http://localhost:8000/logs/stream");
|
||||
const es = new EventSource(`${API_BASE_URL}/logs/stream`);
|
||||
sseRef.current = es;
|
||||
|
||||
es.onmessage = (event) => {
|
||||
|
||||
Reference in New Issue
Block a user