Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion packages/app/src/components/terminal.tsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import type { Ghostty, Terminal as Term, FitAddon } from "ghostty-web"
import ghosttyWasmUrl from "ghostty-web/ghostty-vt.wasm?url"
import { ComponentProps, createEffect, createSignal, onCleanup, onMount, splitProps } from "solid-js"
import { useSDK } from "@/context/sdk"
import { SerializeAddon } from "@/addons/serialize"
Expand Down Expand Up @@ -98,7 +99,7 @@ export const Terminal = (props: TerminalProps) => {

onMount(async () => {
const mod = await import("ghostty-web")
ghostty = await mod.Ghostty.load()
ghostty = await mod.Ghostty.load(ghosttyWasmUrl)

const url = new URL(sdk.url + `/pty/${local.pty.id}/connect?directory=${encodeURIComponent(sdk.directory)}`)
if (window.__OPENCODE__?.serverPassword) {
Expand Down
5 changes: 5 additions & 0 deletions packages/app/src/env.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,8 @@ interface ImportMetaEnv {
interface ImportMeta {
readonly env: ImportMetaEnv
}

declare module "*.wasm?url" {
const url: string
export default url
}