Skip to content

perf: improve page load and rendering performance#294

Draft
Xaroz wants to merge 3 commits intomainfrom
perf/improve-page-load-and-rendering
Draft

perf: improve page load and rendering performance#294
Xaroz wants to merge 3 commits intomainfrom
perf/improve-page-load-and-rendering

Conversation

@Xaroz
Copy link
Copy Markdown
Contributor

@Xaroz Xaroz commented Mar 16, 2026

Summary

Rendering

  • GPU-accelerate background overlaywill-change: transform + translateZ(0) on the grid overlay to eliminate scroll repaints from mask compositing
  • Memoize hot componentsKeyValueRow (100+ per detail page), MessageSummaryRow (40-100 per table)
  • Replace slow wildcard CSS selectors[class*='htw-'] attribute selectors replaced with specific class selectors for widget overrides
  • Reduce accent-glow blur from 20px to 10px

Loading

  • Preload custom fonts via <link rel="preload"> to reduce FOUT
  • Parallelize block explorer URL lookups in ContentDetailsCard (was sequential awaits)
  • Enable Link prefetch on message table rows

Test plan

  • Verify background grid overlay scrolls smoothly
  • Verify widget styling overrides still apply (chain picker, modals, tooltips)
  • Verify fonts load without visible flash
  • Visual check that accent-glow shadow still looks good at 10px
  • OG card previews still work (no SSR changes in this PR)

🤖 Generated with Claude Code

Xaroz and others added 3 commits March 16, 2026 17:11
- GPU-accelerate background overlay with will-change/translateZ(0)
- Memoize KeyValueRow (rendered 100+ times per detail page)
- Replace slow wildcard [class*='htw-'] CSS selectors with specific classes
- Preload custom fonts to reduce FOUT
- Reduce accent-glow blur radius from 20px to 10px

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
- Skip SSR OG data fetching for non-bot user agents (eliminates 3
  network requests on every click from table to detail page)
- Add Cache-Control header for real users (s-maxage=60, stale-while-revalidate)
- Parallelize block explorer URL lookups in ContentDetailsCard
- Memoize MessageSummaryRow (rendered 40-100x per table)
- Enable Link prefetch on message table rows

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown

vercel bot commented Mar 16, 2026

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

Project Deployment Actions Updated (UTC)
hyperlane-explorer Ready Ready Preview, Comment Mar 16, 2026 10:37pm

Request Review


// Cache the response for real users (instant navigation) while bots get fresh data
if (!isBot) {
ctx.res.setHeader('Cache-Control', 'public, s-maxage=60, stale-while-revalidate=300');
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

public, s-maxage=60 on the non-bot HTML is cache-unsafe here. Because the response varies by user agent but doesn’t have a safe cache key split, a CDN can cache the ogData: null human response and serve it to bots, breaking OG tags in the common user-visit-then-share flow. In #295 this is fixed by avoiding shared HTML caching on this route rather than relying on bot/human cache variation.

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.

2 participants