Skip to content

perf: improve homepage Lighthouse score#600

Open
cambrianlab wants to merge 1 commit into
tailcallhq:developfrom
cambrianlab:cambrianlab/homepage-lighthouse-100
Open

perf: improve homepage Lighthouse score#600
cambrianlab wants to merge 1 commit into
tailcallhq:developfrom
cambrianlab:cambrianlab/homepage-lighthouse-100

Conversation

@cambrianlab
Copy link
Copy Markdown

/claim #217

Summary

  • Reworked / into a lightweight static landing page with inline critical styles and no homepage dependency on the full Docusaurus app shell.
  • Moved the shared custom CSS import into the Docusaurus Layout path so docs/blog routes keep their existing styling.
  • Delayed the Robofy chatbot injection from the shared layout instead of loading it as a render-blocking global head script.
  • Added a small post-build plugin that strips the unused Docusaurus CSS/JS from only build/index.html; docs/blog pages continue to ship the normal app bundles.

Lighthouse verification

Ran against the production build served locally with docusaurus serve at /.

Mobile result:

  • Performance: 100
  • Accessibility: 100
  • Best Practices: 100
  • SEO: 100
  • FCP: 0.6 s
  • LCP: 0.8 s
  • TBT: 0 ms
  • CLS: 0
  • Speed Index: 0.6 s
  • Total size: 16 KiB

Commands used:

npm run build
npx lighthouse http://127.0.0.1:3017/ \
  --only-categories=performance,accessibility,best-practices,seo \
  --form-factor=mobile \
  --screenEmulation.mobile=true \
  --screenEmulation.width=390 \
  --screenEmulation.height=844 \
  --screenEmulation.deviceScaleFactor=3 \
  --throttling-method=simulate \
  --chrome-flags='--headless=new --no-sandbox' \
  --output=json \
  --output-path=/tmp/tailcall-lh-pr-mobile.json \
  --quiet

Build note: the existing optional ws dependency warnings for bufferutil and utf-8-validate still appear during build, but the build succeeds.

@cambrianlab cambrianlab changed the title Improve homepage Lighthouse performance perf: improve homepage Lighthouse score May 12, 2026
@nagiexplorer88
Copy link
Copy Markdown

I think this needs a scope check before it can satisfy #217.

The diff does not just optimize the existing homepage: src/pages/index.tsx drops the existing HomePage, Announcement, GA pageview, Scarf pixel, and the existing homepage sections, then static-homepage-plugin strips the CSS/JS only from the built index.html. That can produce a very small 100/100 static page, but it also substantially changes the shipped / content and tracking surface.

Since #217 asks for the release build of the website to reach 100 on /, I would either preserve the current homepage UX while optimizing it, or get explicit maintainer confirmation that replacing it with this reduced landing page is acceptable. Also, the bounty instructions ask for a short demo video in the PR; I do not see one attached yet.

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