A modern, open-source implementation of the classic Spider Solitaire card game, built with React, TypeScript, and Tailwind CSS.
- Classic Gameplay: Authentic Spider Solitaire rules and mechanics.
- Modern UI: Clean, responsive interface designed with Tailwind CSS.
- Smart Features:
- Undo System: Unlimited undo functionality to help you strategize.
- Smart Hints: Intelligent move suggestions when you're stuck.
- Auto-Complete: Automatically detects and handles obvious moves.
- Progress Tracking:
- Detailed statistics (Win rate, Streaks, Best Score, Best Time).
- Daily Challenges.
- Move counter and timer.
- Customization:
- Multiple color themes/schemes.
- Customizable card backs.
- Persistence: Game state and statistics are automatically saved locally.
- Frontend: React 19
- Build Tool: Vite
- Language: TypeScript
- Styling: Tailwind CSS
- State Management: Zustand
- Icons: Lucide React
- Utilities: date-fns, clsx
- Node.js (Latest LTS version recommended)
- npm
-
Clone the repository:
git clone https://github.com/yourusername/spider-solitaire.git cd spider-solitaire -
Install dependencies:
npm install
-
Start the development server:
npm run dev
-
Open your browser and navigate to
http://localhost:5173(or the port shown in your terminal).
To create an optimized production build:
npm run buildThe build artifacts will be stored in the dist/ directory.
This application can be easily deployed using Docker. The image is automatically built and pushed to Docker Hub and GitHub Container Registry (GHCR) on every update to the main branch.
A compose.yaml file is included in the repository for quick deployment.
-
Run the application:
docker compose up -d
-
Open your browser and navigate to
http://localhost:8080.
You can also run the container directly using the Docker CLI.
From Docker Hub:
docker run -d -p 8080:80 --name spider-solitaire lklynet/spider-solitaire:latestFrom GitHub Container Registry:
docker run -d -p 8080:80 --name spider-solitaire ghcr.io/lklynet/spider-solitaire:latestThis repository is configured with GitHub Actions to automatically build and push the Docker image to:
- Docker Hub:
lklynet/spider-solitaire - GitHub Container Registry:
ghcr.io/lklynet/spider-solitaire
These builds occur whenever changes are pushed to the main branch.
This project is open source software. We believe in the power of community and transparent development.
- Learn: Explore the source code to see how a modern React game is architected.
- Contribute: Bug reports, feature requests, and pull requests are welcome!
- Modify: Feel free to fork the repository and customize the game to your liking.
This project is available under the MIT License.