Render the logo img on the SSR pass — no more wordmark-only flash

Fixkamolos
Shipped
May 18, 2026 at 3:43 AM UTC
Author
Kamo
Commit
15a3c48

ThemeLogo's empty-string initial logoSrc + useEffect-to-fill pattern meant the SSR render returned the wordmark fallback, then hydration populated the src. If anything in that chain hiccuped (it did — the hostname was localhost so getThemePath() returned empty and the chain re-resolved every render), the user kept seeing the wordmark forever. Now ThemeLogo: - Reads the SSR-resolved tenant URL straight from OrgContext via a new useThemedPath() hook. The root layout computes themedPath from the request's Host header server-side and threads it through OrgProvider. - Builds the candidate URL list at render time (memoised), starting with the tenant URL when one exists. - Renders the <img> tag from the very first render with src already pointing at the right candidate — no useEffect dance, no empty-src flash, no SSR/hydration mismatch. - onError walks the list forward in-place. Only when every candidate fails does it render the wordmark fallback. Source priority is unchanged: assetBasePath (only used by the styleguide simulator) → tenant MinIO (logo-full-on-dark → logo-full → logo-on-dark → logo) → local /public/ (logo-full.svg → logo.svg) → wordmark fallback. Build 32/32.

All changes

Like what you see shipping?

Every one of these updates lands in your workspace automatically. Start free and watch it grow week after week.

Start Free ForeverView Pricing