Skip to content

sorooshaghaei/react-tic-tac-toe

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 

Repository files navigation

React Tic-Tac-Toe

Introduction

This project is a classic Tic-Tac-Toe game built using React. It demonstrates the use of React components, state management, and handling user interactions through a simple yet interactive game.

Features

  • Play Tic-Tac-Toe with a friend or against yourself
  • Highlights the winning combination
  • Resets the game with a button click

Screenshots

Game Board

tic-tac-toe

Installation

  1. Clone the Repository:

    git clone https://github.com/sorooshaghaei/react-tic-tac-toe.git
  2. Navigate to the Project Directory:

    cd react-tic-tac-toe
  3. Install the Required Dependencies:

    npm install
  4. Run the Application:

    npm start

Usage

  1. Open the application in your browser.
  2. Play the Game: Click on the squares to make a move. The game will automatically detect the winner or a draw.
  3. Reset the Game: Click the "Restart" button to start a new game.

Code Structure

  • /src/components - Contains React components like Game.jsx,and Board.jsx.
  • /src/styles - Contains CSS files for styling.
  • App.js - The main component that renders the game.
  • index.js - Entry point of the application.

Requirements

  • React 17.x or later
  • Node.js 14.x or later

Contributions

Contributions, issues, and feature requests are welcome! Feel free to check the issues page.

About

It's a simple game called tic tac toe

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published