anomalyco / anomalyco/opencode
Embedded web UI assets re-read from disk on every request
Open
@Hona is already working on this.
Since Aug 22, 2026.
- Dominant language
- TypeScript
- Stars
- 209k
- Forks
- 27.5k
- PR merge metrics
- PR metrics pending
Description
Description
The embedded web UI assets (sprites, fonts, index.html) are immutable for the lifetime of the process, but serveUI re-reads each file from disk on every request. The web UI re-requests these on every view, and on cold pages I measured 0.5–2.5s per asset. A bounded in-memory cache of the constructed responses keyed by request path would fix it. Patch ready.
Plugins
None
OpenCode version
1.18.21
Steps to reproduce
opencode servewith the embedded web UI- Open the web UI and navigate between views
- Each asset request hits the disk again and reconstructs the response instead of reusing one built earlier
Screenshot and/or share link
N/A
Operating System
Windows 11
Terminal
Windows Terminal
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.