feat: hot reload

This commit is contained in:
2025-12-17 09:32:05 +08:00
parent e8b2699104
commit f2b53967eb
7 changed files with 95 additions and 32 deletions

View File

@@ -11,6 +11,6 @@ export function getAdminRouterBase(pathname = window.location.pathname): string
export function getApiBaseURL(pathname = window.location.pathname): string {
const tenantCode = getTenantCodeFromPath(pathname)
return `/t/${tenantCode}/v1`
const origin = import.meta.env.DEV ? 'http://localhost:8080' : ''
return `${origin}/t/${tenantCode}/v1`
}