diff --git a/apps/website/e2e/home-bundle.spec.ts b/apps/website/e2e/home-bundle.spec.ts index 1617ba464..b7729f071 100644 --- a/apps/website/e2e/home-bundle.spec.ts +++ b/apps/website/e2e/home-bundle.spec.ts @@ -31,13 +31,15 @@ const REGISTRY_MARKER = 'LangGraph Durable Execution (Python)'; const DOCS_ROUTE = '/docs/langgraph/guides/streaming'; /** - * The fonts the homepage's above-the-fold hero actually renders: Archivo Black - * (the H1), Archivo normal and italic (one next/font instance, so they preload - * together), and JetBrains Mono (the eyebrow and the demo's URL bar). A fifth - * preload is a new High-priority request racing the LCP image on a phone — add - * one only after measuring that it is above the fold. + * The fonts the homepage preloads, identified by family and style. See the + * FONT PRELOADS note in app/layout.tsx for the measurements behind this list: + * on a throttled phone every preloaded font races the hero poster for + * bandwidth, so only faces whose late arrival would visibly hurt are here. + * Archivo italic and JetBrains Mono were measured at -228ms and -224ms of LCP + * each; Archivo normal stays because un-preloading it reflowed the subhead + * (CLS 0.206). Change this list only with a measurement. */ -const MAX_FONT_PRELOADS = 4; +const EXPECTED_PRELOADS = ['Archivo Black normal', 'Archivo normal']; /** * The bodies of the scripts `path` itself requires: the `