fix(desktop): local dev url

This commit is contained in:
Adam
2025-11-05 12:09:22 -06:00
parent 93e6522736
commit 53b5fbfde9
+3 -1
View File
@@ -16,7 +16,9 @@ const port = import.meta.env.VITE_OPENCODE_SERVER_PORT ?? "4096"
const url =
new URLSearchParams(document.location.search).get("url") ||
(location.hostname.includes("opencode.ai") ? `http://${host}:${port}` : "/")
(location.hostname.includes("opencode.ai") || location.hostname.includes("localhost")
? `http://${host}:${port}`
: "/")
const root = document.getElementById("root")
if (import.meta.env.DEV && !(root instanceof HTMLElement)) {