import { AxiosInstance } from "axios"; // config.ts export interface ChatConfig { apiUrl: string; role: string; cdnUrl?: string; webSocketUrl: string; apiClient:AxiosInstance } let chatConfig: ChatConfig; export function initChatConfig(config: ChatConfig) { chatConfig = config; } export function getChatConfig() { if (!chatConfig) { throw new Error("Chat config not initialized. Call initChatConfig first."); } return chatConfig; }