Skip to content

perf: drop globe texture preload hints from landing page - #472

Draft
alukach wants to merge 1 commit into
mainfrom
perf/drop-globe-texture-preload
Draft

perf: drop globe texture preload hints from landing page#472
alukach wants to merge 1 commit into
mainfrom
perf/drop-globe-texture-preload

Conversation

@alukach

@alukach alukach commented Aug 3, 2026

Copy link
Copy Markdown
Contributor

Part of #471.

What

Deletes the two <link rel="preload"> hints for the WebGL globe textures in src/app/(marketing)/page.tsx.

Why

The hints pulled 6.5 MB of textures into the critical window, ahead of the render-blocking stylesheet that gates first paint. On a real-throttled 4G profile, _next/static/css/1e5913857760d7aa.css was requested at 682 ms but did not arrive until 5901 ms — and FCP tracks that arrival exactly.

The preloads had no upside to weigh against that cost. The original comment said they warmed the cache "before the client component mounts", but LiveGlobe is dynamic(..., { ssr: false }) — it mounts after hydration and requests the textures itself either way. The preload only changed when the bytes competed for bandwidth, not whether they were fetched.

Measured impact

Lighthouse 13.4.1, mobile, --throttling-method=devtools:

Metric Before After
FCP 6.1 s 5.3 s
LCP 6.1 s 5.3 s
Blocking CSS arrives 5901 ms 5094 ms

Note that Lighthouse's default simulated throttling shows no change here — Lantern de-prioritizes Low-priority images out of the critical path and hides the contention. Re-measure with --throttling-method=devtools.

This is the first of several fixes; the textures are still oversized at 4096×2048, which #471 tracks separately.

Risk

Low. Deletes two JSX lines, no behavior change — the globe loads its own textures on mount as before.

Verification

  • npm run type-check — 14 errors, identical to the count on clean main (all pre-existing, in analytics/ files)

🤖 Generated with Claude Code

The two `<link rel="preload">` hints pulled 6.5MB of WebGL globe textures
into the critical window, ahead of the render-blocking stylesheet that
gates first paint. On a real-throttled 4G profile that stylesheet was
requested at 682ms but did not arrive until 5901ms.

The preloads had no upside to trade against that: LiveGlobe is
dynamic({ ssr: false }), so it mounts after hydration and requests the
textures itself regardless.

Measured with Lighthouse 13.4.1 (--throttling-method=devtools, mobile):

  FCP 6.1s -> 5.3s
  LCP 6.1s -> 5.3s

Refs #471
@vercel

vercel Bot commented Aug 3, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
source-cooperative Ready Ready Preview Aug 3, 2026 4:27pm

Request Review

@claude

claude Bot commented Aug 3, 2026

Copy link
Copy Markdown
Contributor

Claude finished @alukach's task in 1m 1s —— View job


✅ No blocking issues — safe to merge.

  • Verified the underlying claim: LiveGlobe fetches both assets itself regardless of the preload hints — globeImageUrl="/img/earth-blue-marble.jpg" in src/components/features/globe/LiveGlobe.tsx:536 and new TextureLoader().load("/img/clouds.png", ...) at LiveGlobe.tsx:163. Removing the two <link rel="preload"> tags in src/app/(marketing)/page.tsx:46-48 is purely a scheduling change, not a behavior change — matches the PR description.
  • Diff is a pure deletion + comment update, no logic touched, no new failure modes introduced.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant