We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d4c9814 commit eebbd73Copy full SHA for eebbd73
1 file changed
packages/desktop/src/app.tsx
@@ -29,15 +29,13 @@ declare global {
29
}
30
31
const host = import.meta.env.VITE_OPENCODE_SERVER_HOST ?? "127.0.0.1"
32
-const port = window.__OPENCODE__?.port ?? import.meta.env.VITE_OPENCODE_SERVER_PORT ?? location.port ?? "4096"
+const port = window.__OPENCODE__?.port ?? import.meta.env.VITE_OPENCODE_SERVER_PORT ?? "4096"
33
34
const url =
35
new URLSearchParams(document.location.search).get("url") ||
36
- (location.hostname.includes("opencode.ai")
+ (location.hostname.includes("opencode.ai") || location.hostname.includes("localhost")
37
? `http://${host}:${port}`
38
- : location.hostname.includes("localhost") || location.hostname === "127.0.0.1"
39
- ? `${location.protocol}//${location.host}`
40
- : "/")
+ : "/")
41
42
export function App() {
43
return (
0 commit comments