The best way to control Claude Code, Codex and more from any computer or phone

main
md 19 lines 1.26 KB
Rendered Raw
1 # Ghostty web terminal
2
3 This directory is the browser adapter for the same official `libghostty-vt` C ABI used by Android.
4 It is intentionally not an xterm compatibility layer.
5
6 - `runtime.ts` owns the singleton WebAssembly instance and runtime ABI layouts.
7 - `vendor/ghostty-write-pty.wasm` is a 112-byte callback trampoline for terminal-generated PTY replies.
8 - `core.ts` owns per-terminal Ghostty handles and translates the C ABI into render snapshots.
9 - `renderer.ts` batches backgrounds and style runs into a Canvas 2D frame.
10 - `surface.ts` owns browser input, IME, selection, scrolling, sizing, links, and cursor blinking.
11 - `fonts/` vendors the symbols-only Nerd Font (MIT) the surface registers lazily, so
12 prompt glyphs render without a locally installed Nerd Font.
13 - `vendor/` holds only the artifacts, reproducibly generated by
14 `apps/web/scripts/build-libghostty-wasm.sh`. The upstream pin and license live once, at
15 `native/libghostty-vt/` at the repository root; the wasm embeds the pinned revision
16 in its build info and the ABI test verifies it against mobile's `VERSION`.
17
18 Keep browser behavior here and terminal transport in the existing client runtime. Do not add React
19 state to the render loop. Both WASM artifacts are ordinary read-only assets, not executables.