{# boot_theme mirrors themeLogic.isDarkModeOn (posthog/utils.py): "dark", "system", or "light" #}
{# head.html first: it carries , which must stay within the first 1024 bytes #} {# so the browser's encoding prescan finds it #} {% include "head.html" %} {# Critical CSS for the pre-React shell (background, spinner, boot-failure message), so the #} {# page doesn't flash white. Everything visual is scoped to #root:empty and .Preloader ā the #} {# app never styles background itself, so an unscoped rule here would persist after #} {# boot and bleed through the themed app. These selectors stop matching once React renders #} {# real content. #} {# Resource hints so the boot chain (font, CSS, entry -> App chunks) is fetched in parallel #} {# instead of discovered as a waterfall. Empty in dev mode and when no build manifest exists. #} {% if js_url %} {% endif %} {% if preload_font_url %} {% endif %} {% if preload_css_url %} {# Preload only ā the loader script injected at the end of appends the actual #} {# stylesheet link (with its hashless fallback). Applying the stylesheet there keeps a #} {# slow CSS fetch from blocking the parser-inserted boot scripts, and keeps the CSSOM #} {# to a single copy. crossorigin matches the loader's fetch mode so one response is reused. #} {% endif %} {% for url in preload_js_urls %} {% endfor %} {% include "overlays.html" %}