Light/dark theming without the flash

Theme switching that flashes the wrong color on navigation is a classic SSR pitfall. The fix: apply the stored theme in an inline script before first paint, drive colors through CSS custom properties, and let prefers-color-scheme be the default.

← Back to all posts