🤖 fix: restore browser favicon loading in web UI #2380
+198
−16
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.
Summary
Fix browser-tab favicon rendering when mux is loaded in Chrome by serving and referencing favicon assets in a way that works in both source-tree server mode and built/dist mode.
Background
In browser mode, users could see a tab title but no favicon. This came from a few compounding issues:
public/assets at rootindex.htmlfor missing asset requests (including favicon lookups).icoextension, which can produce MIME/type mismatches in browser contextsImplementation
index.htmlfavicon references to use relative PNG paths (favicon.png,icon.png) for browser compatibility behind URL prefixes.ThemeContextto use PNG assets and resolve URLs againstdocument.baseURI.resolveOrpcStaticDir()insrc/node/orpc/server.tsto detect both dist and source layouts.resolvedStaticDirresolvedStaticDir/publicwhen presentServerServiceto useresolveOrpcStaticDir()..icoand.pngfavicons.dist/**/*.icoto npmfilesso ico assets are included in published package artifacts.Validation
make static-check✅bun test src/node/orpc/server.test.ts src/browser/contexts/ThemeContext.test.tsx✅Risks
Generated with
mux• Model:openai:gpt-5.3-codex• Thinking:xhigh• Cost:$0.73