Repository navigation
fix(server): serve the terminal WebAssembly module compressed, as application/wasm - #2953
Merged
Merged
Conversation
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 28 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. |
Owner
Author
|
Merge note: GitHub required checks green at this head, omo CLEAR, threads resolved. The ghostty wasm is now served compressed (1.11 MB -> 345 KB br) and cached by the service worker, so a re-open fetches 0 bytes. |
devswha
added a commit
that referenced
this pull request
Nov 5, 2026
…#2976) ## What Settings > Terminal > Draw with libghostty (#2908) is on by default. - It still only draws on a herdr-core server (`terminal-history`, as the desktop app runs); on herdr and mirrored panes xterm.js draws exactly as before. - The setting stays, per device. A device that turned it off stays off: a stored `false` is kept, only a missing or invalid value means on. Note: since #2908 every settings save writes this key, so a device that saved any setting on a main build after #2908 also has `false` stored and stays off; released versions never had the key, so their users get the new default. ## Gates (step 1 checklist, measured on isolated hc 0.1.17 + this stack) | Gate | Result | |---|---| | Phone first load (slow 4G 1.6 Mbps/150 ms, CPU x4, fresh profile, median of 5) | off 7,510 ms / on 7,918 ms: +408 ms, within +0.5 s (wasm served br since #2953: 1.11 MB -> 345 KB, re-open fetches no wasm) | | Low-end phone frames (CPU x6, `seq 1 200000`, ABBA) | after #2959 on is at or below off: median finish 10.5 s vs 10.8 s, stalls > 50 ms 4 vs 7 | | Screen reader (real NVDA 2026.2, Windows 11 VM, Edge 156) | on: NVDA reads new output; off (xterm, screen reader mode off): reads nothing. Known follow-ups in #2963 | | iOS long-press copy (iOS 27 Simulator, Safari) | **provisionally equal**: neither xterm nor libghostty shows a selection/copy menu on a 1.6 s long-press (driven with simctl + AXe touch). Pending one manual check once Simulator components are installed on the test Mac. Copy keeps working through the key bar's copy button and OSC 52 (#2925) | ## Validation - `bun test src/lib/settings`: pass (the two tests that pinned the old default now pin the new one: missing/invalid means on, a stored `false` stays off, the key stays out of the whole-record save). - `bun scripts/terminal-ghostty-demo-regression.ts`: pass (herdr-core pane drawn with libghostty, herdr's own and off stay xterm). - `bun run check fast`: pass (exit 0) on this head
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The terminal's WebAssembly module (Settings > Terminal > Draw with libghostty, #2908) was sent uncompressed and as
application/octet-stream: 1,110,716 bytes on every first load. The build already writes.br/.gzcopies next to it (#2908 addedwasmtoscripts/compressed-assets.ts), butserveStaticonly negotiates precompressed copies for/assets/*.js|css.server/static.ts:/assets/*.wasmis negotiated like js/css (br, gzip, identity, 406 when none is acceptable), immutable cache, and served asapplication/wasm.Validation
server/static-encoding.test.ts: new case serves a wasm fixture as br and gzip withapplication/wasm, and identity without encoding; it fails on main (content-encodingnull).bun test server/static-encoding.test.ts server/static.test.ts: pass.bun run check fast: pass (exit 0) on this head.curl -H 'Accept-Encoding: br': 200, 344,901 bytes,application/wasm(was 1,110,716).ovis-v4-sheep-<build>).