Skip to content

chore(website): drop unused estimate-score API + speed up demo animation#171

Merged
aidenybai merged 2 commits intomainfrom
cursor/website-cleanup-and-anim-tuning-0d9b
May 8, 2026
Merged

chore(website): drop unused estimate-score API + speed up demo animation#171
aidenybai merged 2 commits intomainfrom
cursor/website-cleanup-and-anim-tuning-0d9b

Conversation

@aidenybai
Copy link
Copy Markdown
Member

@aidenybai aidenybai commented May 8, 2026

Summary

Polish + cleanup pass on the marketing site.

1. Delete dead code

Removed packages/website/src/app/api/estimate-score/route.ts. Nothing in the repo (CLI, react-doctor package, or website) calls /api/estimate-score — the CLI only ever talks to /api/score (SCORE_API_URL in packages/react-doctor/src/constants.ts). The estimate endpoint duplicated the scoring/validation logic of /api/score and was unreachable from any client surface.

A wider sweep of the website (page.tsx, terminal.tsx, share/*, share/badge, share/og, install-skill, globals.css, public assets) didn't turn up other clearly-dead modules — the share/badge/og routes are all reachable from the CLI's buildShareUrl, and the install-skill route is intentionally kept for curl | bash installs.

2. Faster typing in the terminal demo

TYPING_DELAY_MS: 5025. The npx -y react-doctor@latest . command now types in roughly half the time.

3. Quicker diagnostic stagger

DIAGNOSTIC_MIN_DELAY_MS / DIAGNOSTIC_MAX_DELAY_MS: 150–35060–140. The React Doctor findings still reveal one-by-one with a small randomized cadence, but the whole list lands much faster.

4. Tighter inter-section delays

The pauses between phases were the slowest part of the demo. Roughly halved:

  • INITIAL_DELAY_MS: 500250 (pre-typing)
  • PROJECT_SCAN_DELAY_MS: 800350 (after the command finishes typing)
  • POST_HEADER_DELAY_MS: 600250 (after the react-doctor header)
  • SCORE_REVEAL_DELAY_MS: 600250 (between findings and score reveal)
  • POST_SCORE_DELAY_MS: 700300 (between score and the CTA summary)

The animation still has natural breathing room between phases, but it gets to the score and CTA roughly twice as fast end-to-end.

Verification

  • pnpm lint
  • pnpm typecheck ✅ (also ran tsc --noEmit directly inside packages/website)
  • pnpm format:check
  • pnpm test ✅ (619 tests pass)
Open in Web Open in Cursor 

- Remove /api/estimate-score route; nothing in this repo (CLI, react-doctor package, or website) calls it. The only score endpoint actually used by the CLI is /api/score.

- Halve TYPING_DELAY_MS (50ms -> 25ms) so the command types in noticeably faster.

- Tighten the diagnostic stagger window (150-350ms -> 60-140ms) so the React Doctor findings reveal more snappily.

Co-authored-by: Aiden Bai <aidenybai@users.noreply.github.com>
@vercel
Copy link
Copy Markdown

vercel Bot commented May 8, 2026

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

Project Deployment Actions Updated (UTC)
react-doctor-website Ready Ready Preview, Comment May 8, 2026 10:23am

@aidenybai aidenybai marked this pull request as ready for review May 8, 2026 10:22
Halve the inter-section pauses so the demo flows more snappily without losing the rhythm between phases:

- INITIAL_DELAY_MS: 500 -> 250 (pre-typing)

- PROJECT_SCAN_DELAY_MS: 800 -> 350 (after command finishes typing)

- POST_HEADER_DELAY_MS: 600 -> 250 (after react-doctor header)

- SCORE_REVEAL_DELAY_MS: 600 -> 250 (between findings and score)

- POST_SCORE_DELAY_MS: 700 -> 300 (between score and summary CTA)

Co-authored-by: Aiden Bai <aidenybai@users.noreply.github.com>
@aidenybai aidenybai merged commit 36518ba into main May 8, 2026
6 checks passed
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