From 93f4ba4a57cb18a87f5c59c2a37d59665ac184ea Mon Sep 17 00:00:00 2001 From: Fuwn Date: Tue, 20 Jan 2026 04:27:05 -0800 Subject: fix: Prevent flash of light mode on page load Move theme detection script to the very top of , before any stylesheets load. This ensures the 'dark' class is added to before the browser starts rendering with CSS, eliminating the flash of unstyled/wrong-theme content. --- internal/server/templates/index.html | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'internal/server') diff --git a/internal/server/templates/index.html b/internal/server/templates/index.html index 6bdfeff..025df89 100644 --- a/internal/server/templates/index.html +++ b/internal/server/templates/index.html @@ -1,6 +1,12 @@ + {{.Site.Name}} @@ -17,12 +23,6 @@ {{.ThemeCSS}} {{end}} -
-- cgit v1.2.3