Skip to content

4ssh1/Tic-tac-toe

Repository files navigation

A Tic-tac-toe game

A fun and interactive Tic-Tac-Toe game with additional features like undo, redo and reset functionality, making it more engaging and user-friendly.

Features

  • Undo/Redo : Revisit previous moves or redo undone moves seamlessly.

  • Reset Game : Start a fresh game anytime with the reset button.

  • Winning Highlights : Hightlights the winning squares in green for clear visualization.

    Technologies Used

    • React

How to Play

  1. Players take turns marking a square with "X" or "O"
  2. The first player to get three in a row (horizontally, vertically or diagonally) wins.
  3. Use the undo and redo buttons to revisit moves.
  4. Click reset to start a new game.

Installation

To get started, follow these steps:

  1. Clone the repository:

      git clone https://github.com/4ssh1/Tic-tac-toe.git
      cd Tic-tac-toe
  2. Install dependencies:

      npm install
  3. Start the server:

      npm run dev

Tic-tac-toe Project Structure

Tic-tac-toe/
├── public/                 # Static files
├── src/
│   ├── components/         # React components
│   │   └── Board.js        # Game board logic
│   │   └── Square.js       # Individual square component
│   ├── App.js              # Main application component
│   ├── index.js            # React entry point
│   └── styles.css          # Styling for the game
├── package.json            # Project metadata and dependencies
├── README.md               # Project documentation
└── .gitignore              # Ignored files in Git    

Contributing

We welcome contributions! To contribute:

  1. Fork the repository.

  2. Create a new branch:

     git checkout -b feature-name
  3. Commit your changes and push them to your fork.

  4. Create a pull request.

License

This project is licensed under the MIT license.

Releases

No releases published

Packages

No packages published