app-darts Tailwind Templates

App Darts

A modern, responsive darts game scorer built with Next.js, TypeScript, and Tailwind CSS โ€“ supports multiple game modes, multiple player, and detailed history tracking.

๐ŸŽฏ Darts Game Scorer

A modern, responsive web app for scoring darts games with customizable features and detailed history tracking.


๐Ÿš€ Features

  • ๐ŸŽฎ Game Modes: Play 301, 501, or 701
  • ๐ŸŽฏ Double-Out Support: Follows standard finishing rules
  • ๐Ÿ‘ฅ Multi-Player: Add and manage unlimited players
  • ๐ŸŽจ Customizable UI: Set multiplier colors to your preference
  • ๐Ÿ“Š Game History: View detailed throw logs for each player
  • ๐Ÿ“ฑ Responsive Design: Optimized for desktop, tablet, and mobile
  • ๐ŸŒ— Dark & Light Mode: Auto theme switching based on system
  • ๐Ÿ’พ Persistent Storage: Game state saved in local storage

๐Ÿ› ๏ธ Tech Stack

  • Next.js โ€“ React framework for frontend rendering
  • TypeScript โ€“ Type-safe JavaScript
  • Tailwind CSS โ€“ Utility-first CSS styling
  • Radix UI โ€“ Accessible, headless UI components
  • Lucide Icons โ€“ Consistent and customizable icons
  • shadcn/ui โ€“ Beautiful prebuilt UI components

๐Ÿง‘โ€๐Ÿ’ป Getting Started

โœ… Prerequisites

  • Node.js v18+
  • npm

๐Ÿ”ง Local Development

  1. Clone the repo:
    git clone https://github.com/yourusername/darts-game.git
    cd darts-game
    
  2. Install dependencies:
    npm install --legacy-peer-deps
    
  3. Run the dev server:
    npm run dev
    
  4. Visit http://localhost:3000 in your browser.

๐Ÿณ Docker Setup

  1. Build the image:
    docker build -t app-darts .
    
  2. Run the container:
    docker run -p 3000:3000 app-darts
    
  3. Visit http://localhost:3000

๐ŸŽฎ How to Use

๐Ÿงพ Setup

  1. Click the โš™๏ธ Settings icon
  2. Add players and select game mode
  3. (Optional) Set custom multiplier colors
  4. Click Start Game

๐ŸŽฏ Scoring

  1. Choose a multiplier: ร—1, ร—2, or ร—3
  2. Tap the number you hit
  3. Complete your throws or click Finish Round

๐Ÿ•น๏ธ Game Controls

  • Reset Round โ€“ Clear current throws
  • Next Player โ€“ Advance to the next player
  • History Icon โ€“ View throw history

โœ๏ธ Edit Scores

  • Click the โœ๏ธ edit icon next to a player's score to adjust manually

๐Ÿงฑ Project Structure

app-darts/
โ”œโ”€โ”€ app/
โ”‚   โ”œโ”€โ”€ layout.tsx
โ”‚   โ”œโ”€โ”€ page.tsx
โ”‚   โ””โ”€โ”€ globals.css
โ”œโ”€โ”€ components/
โ”‚   โ”œโ”€โ”€ ui/
โ”‚   โ”œโ”€โ”€ darts-game.tsx
โ”‚   โ”œโ”€โ”€ score-input.tsx
โ”‚   โ”œโ”€โ”€ game-stats.tsx
โ”‚   โ”œโ”€โ”€ player-management.tsx
โ”‚   โ”œโ”€โ”€ game-history-sheet.tsx
โ”‚   โ”œโ”€โ”€ throw-history.tsx
โ”‚   โ”œโ”€โ”€ color-settings.tsx
โ”‚   โ”œโ”€โ”€ edit-score-dialog.tsx
โ”‚   โ””โ”€โ”€ theme-toggle.tsx
โ”œโ”€โ”€ lib/
โ”‚   โ””โ”€โ”€ utils.ts
โ”œโ”€โ”€ public/
โ”œโ”€โ”€ next.config.mjs
โ”œโ”€โ”€ tailwind.config.ts
โ”œโ”€โ”€ tsconfig.json
โ”œโ”€โ”€ package.json
โ”œโ”€โ”€ Dockerfile
โ””โ”€โ”€ README.md

๐Ÿง  Technical Details

๐Ÿ—‚๏ธ State Management

  • Uses useState & useEffect
  • Tracks:
    • Player list & scores
    • Current player & throws
    • Game mode & color prefs
    • UI modals/sheets

๐Ÿ’พ Local Storage

  • Player data
  • Selected game mode
  • Color preferences

๐Ÿ“ฆ Production

๐Ÿ”จ Build

npm run build

๐Ÿš€ Deployment

  1. Push your changes to GitHub

  2. Update the deployment in your Flux GitOps repo:

    • Create or edit a Kustomization and Deployment or HelmRelease
    • Ensure your image is built and pushed via CI
    • Optionally configure image automation
  3. Flux will reconcile and deploy to your cluster

๐Ÿ“˜ See cellexec/flux-gitops for full setup.


๐Ÿ› ๏ธ Troubleshooting

Issue Solution
โŒ Dependency errors Use --legacy-peer-deps with npm install
๐Ÿ”ง Build errors Use Node.js v18+
๐Ÿงน Storage bugs Clear browser local storage
๐ŸŽจ Style glitches Check Tailwind setup/config

โœ… Browser Support

  • Chrome, Firefox, Safari, Edge (latest)
  • iOS Safari & Android Chrome

๐Ÿ“ Game Rules

๐ŸŽฏ Double Out (Standard)

  1. Start with 301, 501, or 701

  2. Subtract each roundโ€™s score from your total

  3. To win, a player must:

    • Hit exactly 0
    • Finish with a double (e.g., outer bull or double ring)
  4. Busts (overshoot or 1 point left) = No score for the round


๐Ÿค Contributing

  1. Fork the repo
  2. Create a branch: git checkout -b feature/amazing-feature
  3. Commit: git commit -m "Add amazing feature"
  4. Push: git push origin feature/amazing-feature
  5. Open a Pull Request

๐Ÿ“„ License

MIT License โ€” free to use, modify, and share.

Top categories

tailwind logo

Need a Tailwind website built?

Hire a professional TailwindCSS developer today.
Loading Svelte Themes