Skip to content

feat(scaffold): add package scripts, configs, lockfile, and CI workflow - #1

Merged
prateekchaplot merged 3 commits into
mainfrom
arch/cricket-manager/t01
Nov 17, 2026
Merged

prateekchaplot merged 3 commits into
mainfrom
arch/cricket-manager/t01

Conversation

@prateekchaplot

Copy link
Copy Markdown
Owner

Task T01 from docs/ARCHITECTURE.md §14.

What was built

  • package.json — exact §5 pins: React 19.3.1, React Router 8.5.1, Zod 4.6.7, Vite 8.3.8, Vitest 5.1.0, Testing Library React 16.3.0, jsdom 27.2.0, Playwright 1.65.1, ESLint 9.39.1, Prettier 3.6.2, vite-plugin-pwa 2.0.0, pnpm 10.24.0 via packageManager; scripts for dev / build / preview / test / e2e / typecheck / lint / format
  • pnpm-lock.yaml — reproducible lockfile (513 packages, frozen install verified)
  • TypeScript strict configs (project references, no-Emit build), ESLint 9 flat config, Prettier, .gitignore, .npmrc
  • vite.config.ts (Vitest jsdom setup, optional VITE_PUBLIC_BASE_PATH base per §11) and playwright.config.ts (Chromium, vite preview webServer)
  • Minimal index.html + placeholder src/main.tsx so the static app builds and starts (T07 replaces with the real shell)
  • .github/workflows/ci.yml with all §13 stages: frozen install → format → lint → typecheck → unit/component tests → production build → Playwright Chromium smoke; actions pinned to release SHAs, Node 24.11.1

Deviations (recorded in docs/TASKS.md Notes)

  • TypeScript 6.0.3 instead of §5's 7.0.2. typescript@7.0.2 ships only the native compiler with no JS API, and no typescript-eslint release supports it (latest 8.73.0 peers typescript >=4.8.4 <6.1.0). This also bumps typescript-eslint 8.48.0 → 8.73.0 (the §5 pin rejects TS 6.0.x). TS 7 adoption is deferred until lint tooling supports native TS 7; promoting it requires a §5 contract change via the shared-file protocol.
  • Supporting deps not itemized in §5, required for named capabilities: @vitejs/plugin-react 6.3.0, @types/react 19.3.0, @types/react-dom 19.3.0, @types/node 24.19.2, @eslint/js 9.39.1.

Verification

  • pnpm install --frozen-lockfile — lockfile up to date, reproducible
  • pnpm format:check — all files pass
  • pnpm lint — ESLint clean
  • pnpm typecheck — tsc -b clean (TypeScript 6.0.3)
  • pnpm test -- --passWithNoTests — Vitest 5.1.0 passes with zero test files (tests arrive from T02 on)
  • pnpm build — production bundle: index 0.46 kB, assets 219.71 kB (68.70 kB gzip)
  • pnpm test:e2e -- --pass-with-no-tests — Playwright 1.65.1 passes with zero specs
  • Manual: vite preview serves the app shell (HTTP 200, title rendered)

Next

T02 — shared schemas/errors/IDs (src/shared, src/game/types.ts, src/game/data/*) per the §14.3 parallelization map. Suggested merge method: squash with branch deletion.

@prateekchaplot

Copy link
Copy Markdown
Owner Author

CI fix pushed (d41c035) — root cause: pnpm's -- separator handling differs by platform. On Windows (local) pnpm consumes -- and Vitest received --passWithNoTests as a real flag; on Linux (CI, same pnpm 10.24.0) it forwarded -- verbatim, so Vitest treated post--- args as positional file filters and the flag never applied → exit 1 on zero test files.

Fix: zero-test tolerance moved into config (test.passWithNoTests: true in vite.config.ts, CI runs pnpm test bare) and the e2e step now uses pnpm exec playwright test --pass-with-no-tests (direct arg forwarding, no separator ambiguity). Same latent bug fixed in the e2e step before it ever ran.

Re-verification: full local sequence green with the exact CI commands; CI run 44133179053 passed all stages in 1m01s, including Playwright Chromium install and browser smoke stage.

@prateekchaplot
prateekchaplot merged commit a9c9b99 into main Nov 17, 2026
1 check passed
@prateekchaplot
prateekchaplot deleted the arch/cricket-manager/t01 branch November 17, 2026 17:08
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