* fix: lower darts ELO_DIVISOR to 400 and fallback Elo to 1400 ELO_DIVISOR 500 → 400: elite darts is more skill-dominated than the previous setting implied. A 400-point gap now gives ~78% per-set win probability (vs ~73% before). fallbackElo 1600 → 1400: unseeded PDC World Championship entrants (regional qualifiers, Q-School players) are materially weaker than seeded tour professionals. 1400 better reflects that gap. Combined effect: a dominant player (e.g. 2000 Elo vs 1400-1600 field) now produces EV ≈ 65 instead of ≈ 30, which better matches expectations for a top-ranked player in a 128-player bracket. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * fix: lower darts ELO_DIVISOR to 200 for realistic EV distribution With the actual PDC field (top players clustered 1800–1970 Elo, Littler at ~2080), ELO_DIVISOR=400 made the gap between world #1 and the top 8 too soft — EV for Littler came out ~37 instead of the expected 65–70. ELO_DIVISOR=200 calibrates correctly for this field: a 100-pt gap now gives ~62% per-set win probability (vs ~56% at 400), sharply rewarding the best players while still allowing upsets. Littler at 2084 produces EV ≈ 65–70 against the real PDC tour roster. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * fix: seed darts bracket by Elo instead of world ranking World ranking (PDC Order of Merit) is prize-money-based and can diverge from current skill — e.g. Kevin Doets (1818 Elo) was ranked 35th while Joe Cullen (1667 Elo) held the 32nd seed. Seeding the weaker player and leaving the stronger one unseeded contradicts the Elo-based match model. Seeding by Elo descending ensures the 32 strongest players (by the same metric used to compute match probabilities) get protected bracket positions. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * revert: restore world-ranking-based seeding for darts bracket Seeding should follow the PDC Order of Merit (world ranking), not Elo. Reverts the previous Elo-seeding commit. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> * fix: interleave seeded and unseeded R1 pairs in darts bracket Previously, all 32 seeded-vs-unseeded matches were added to r1Pairs first (indices 0–31) and all 32 unseeded-vs-unseeded matches last (indices 32–63). Since R2 pairs adjacent R1 winners, this created two completely separate sub-brackets that only converged at the Final: - Seeded sub-bracket: top players eliminating each other early - Unseeded sub-bracket: high-Elo unseeded players (e.g. Doets 1818, Zonneveld 1806) steamrolling weak opponents and making the Final ~20% of the time Fix: interleave each seeded match with its adjacent unseeded-vs-unseeded match. Seeded pair i is at r1Pairs[2i], unseeded pair i is at r1Pairs[2i+1]. From R2 onwards, winners from seeded and unseeded regions now merge correctly as in a real single-elimination bracket. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com> --------- Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com> |
||
|---|---|---|
| .claude | ||
| .github/workflows | ||
| .storybook | ||
| .vscode | ||
| app | ||
| cypress | ||
| database | ||
| drizzle | ||
| plans | ||
| public | ||
| scripts | ||
| server | ||
| .dockerignore | ||
| .env.example | ||
| .gitignore | ||
| .mcp.json | ||
| .nvmrc | ||
| .oxlintrc.json | ||
| CLAUDE.md | ||
| components.json | ||
| cypress.config.js | ||
| docker-compose.yml | ||
| Dockerfile | ||
| drizzle.config.ts | ||
| instrument.server.mjs | ||
| package-lock.json | ||
| package.json | ||
| plan.md | ||
| react-router.config.ts | ||
| README.md | ||
| server.ts | ||
| TESTING.md | ||
| tsconfig.json | ||
| tsconfig.node.json | ||
| tsconfig.server.json | ||
| tsconfig.vite.json | ||
| vite.config.ts | ||
| vitest.config.ts | ||
| vitest.shims.d.ts | ||
Welcome to React Router!
A modern, production-ready template for building full-stack React applications using React Router.
Features
- 🚀 Server-side rendering
- ⚡️ Hot Module Replacement (HMR)
- 📦 Asset bundling and optimization
- 🔄 Data loading and mutations
- 🔒 TypeScript by default
- 🎉 TailwindCSS for styling
- 💾 PostgreSQL + DrizzleORM
- 📖 React Router docs
Getting Started
Installation
Install the dependencies:
npm install
Development
Copy .env.example to .env and provide a DATABASE_URL with your connection string.
Run an initial database migration:
npm run db:migrate
Start the development server with HMR:
npm run dev
Your application will be available at http://localhost:5173.
Building for Production
Create a production build:
npm run build
Deployment
Docker Deployment
To build and run using Docker:
# For npm
docker build -t my-app .
# Run the container
docker run -p 3000:3000 my-app
The containerized application can be deployed to any platform that supports Docker, including:
- AWS ECS
- Google Cloud Run
- Azure Container Apps
- Digital Ocean App Platform
- Fly.io
- Railway
DIY Deployment
If you're familiar with deploying Node applications, the built-in app server is production-ready.
Make sure to deploy the output of npm run build
├── package.json
├── package-lock.json (or pnpm-lock.yaml, or bun.lockb)
├── server.js
├── build/
│ ├── client/ # Static assets
│ └── server/ # Server-side code
Styling
This template comes with Tailwind CSS already configured for a simple default starting experience. You can use whatever CSS framework you prefer.
Built with ❤️ using React Router.