Add CI, fix typecheck, refresh docs, and normalize formatting - #18
Conversation
Repo health pass across tooling, types, and docs: - CI: add GitHub Actions workflow (.github/workflows/ci.yml) running lint, typecheck, unit tests, and build on Node 24, plus a separate Playwright e2e job. The repo had tests but nothing enforced them. - Typecheck: `tsc --noEmit` previously failed on test files because the @testing-library/jest-dom matcher types were only registered at runtime in the root vitest.setup.ts (outside each project's tsconfig). Add a declaration in each TS project to load the augmentation, plus a `typecheck` script in web and @repo/ui, a turbo task, and a root script. - Dockerfile: bump both stages node:20-alpine -> node:24-alpine to match engines.node (24.x). Not built locally (no Docker available). - Docs: rewrite CODE_FLOW.md to match the current architecture (CSS animations instead of framer-motion, the /api/quotes/[author] route, ThemeToggle, real caching/timeout/fallback behavior). Remove the vestigial unstable_noStore mock from data.test.ts (data.ts no longer imports it). Fix README `npm build`/`npm dev` -> `npm run ...` and add a Test section. - Formatting: add .prettierignore (so `npm run format` skips build output) and run prettier, normalizing the tab/space mix across source files. Verified: lint, typecheck, unit tests (5/5), build, and e2e all pass. Co-Authored-By: Claude Opus 4.8 <[email protected]>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Warning Review limit reached
More reviews will be available in 17 minutes and 4 seconds. Learn how PR review limits work. Your organization has used up its prepaid credits, and credit purchases are no longer available. Enable the review add-on in the billing tab to keep reviews running — you're only billed for reviews past your plan's rate limits ($0.25/file). ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based credits. 🚦 How do rate limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan refill rate. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, the refill rate gradually slows as usage increases. The highest same-day bursts are limited more strictly. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (22)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Overview
A repo-health pass: adds CI, makes a standalone type-check pass, refreshes drifted documentation, and normalizes formatting. No runtime/behavior changes to the app.
What changed & why
CI (new)
.github/workflows/ci.yml— on every push tomainand PR, runs two jobs on Node 24:lint→typecheck→ unit tests →buildTypecheck fix (+ scripts)
tsc --noEmitpreviously failed on the test files (toBeVisible,toHaveClass, … "does not exist on type Assertion"). Root cause: the@testing-library/jest-dommatcher types were only registered at runtime in the rootvitest.setup.ts, which lives outside each project'stsconfiginclude.apps/web/types/testing-library.d.ts,packages/ui/src/testing-library.d.ts) that loads the augmentation.typecheckscript toweband@repo/ui, atypecheckturbo task, and a rootnpm run typecheck.tscnow passes cleanly across the monorepo.Dockerfile
node:20-alpine→node:24-alpineto matchengines.node(24.x).Docs
CODE_FLOW.mdto match the current architecture: CSS animations (no framer-motion), the/api/quotes/[author]route handler,ThemeToggle, and the real caching/timeout/fallback behavior. The previous version described a removed framer-motion/unstable_noStoredesign.next/cacheunstable_noStoremock fromdata.test.ts(data.tsno longer imports it).README.md: fixednpm build/npm dev→npm run build/npm run dev; added a Test section.Formatting
.prettierignoresonpm run formatno longer rewrites.next/build output (Prettier only auto-ignoresnode_modules).npm run format, normalizing the tab/space mix. This accounts for most of the diff's line count (e.g.data.tsis whitespace-only).Verification
All green locally:
lint✅ ·typecheck✅ · unit tests 5/5 ✅ ·build✅ · e2e 1/1 ✅ (also run withCI=1).Reviewer notes
CODE_FLOW.md, and the Dockerfile Node bump.packages/ui/src/utils/animate.tsxis dead code (framer-motion variants nothing imports; framer-motion is no longer a dependency) and can be removed separately.🤖 Generated with Claude Code