fix(miniapp): add build-time runtime config asset

This commit is contained in:
2026-03-09 16:50:55 +04:00
parent 63a2677601
commit 12f33e7aea
3 changed files with 8 additions and 1 deletions

View File

@@ -7,6 +7,10 @@ declare global {
}
export function runtimeBotApiUrl(): string | undefined {
if (typeof window === 'undefined') {
return undefined
}
const configured = window.__HOUSEHOLD_CONFIG__?.botApiUrl?.trim()
return configured && configured.length > 0 ? configured : undefined