Skip to content

feat(docs): add preconnect demo to Resource Hints page - #88

Merged
nucliweb merged 1 commit into
mainfrom
feat/resource-hints-demo
Jul 3, 2026
Merged

feat(docs): add preconnect demo to Resource Hints page#88
nucliweb merged 1 commit into
mainfrom
feat/resource-hints-demo

Conversation

@nucliweb

@nucliweb nucliweb commented Jul 3, 2026

Copy link
Copy Markdown
Owner

What

Adds the interactive network-waterfall demo to the Resource Hints page, under a new "Why Preconnect Helps" section. Continues the interactive-demos rollout started in #87 (FSL and Long Task).

Readers can switch between four scenarios, HTTP/1.1 Connection: close, HTTP/1.1 keep-alive, HTTP/2, and HTTP/2 + preconnect, to see how preconnect moves the connection setup (DNS, TCP, TLS) off the critical path.

Why

The page documents every resource hint but had no visualization of why preconnect helps. The demo adds that temporal "why" a static diagram cannot convey. Framing is intentionally centered on preconnect (the demo's climax scenario); the HTTP-version comparison is context for what a reused connection saves.

Changes

  • Embed network-waterfall demo via the existing Demo component (heightKey="netWaterfallHeight").
  • Copy the self-contained demo HTML into public/demos/.

Verification

Verified at runtime (next dev): iframe renders inline, auto-height works (627px, content-fit), all four scenario tabs are interactive, light/dark theme syncs, and check:consistency passes.

Embed the network-waterfall demo under a new "Why Preconnect Helps" section, letting readers compare connection reuse across HTTP/1.1, keep-alive, HTTP/2, and HTTP/2 + preconnect, and see how preconnect moves the connection setup (DNS, TCP, TLS) off the critical path.
@vercel

vercel Bot commented Jul 3, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated (UTC)
webperf-snippets Ready Ready Preview, Comment Jul 3, 2026 4:29pm
webperf-snippets-u6am Ready Ready Preview, Comment Jul 3, 2026 4:29pm

@nucliweb
nucliweb merged commit e8804c7 into main Jul 3, 2026
4 checks passed
@nucliweb
nucliweb deleted the feat/resource-hints-demo branch July 3, 2026 16:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant