Skip to content

Files

91 lines (70 loc) · 1.54 KB

README.md

File metadata and controls

91 lines (70 loc) · 1.54 KB

Snake Game

This project is a classic Snake Game built using React. The game allows users to control a snake to eat food and grow in size while avoiding collisions with the walls or itself.

Getting Started

These instructions will help you set up and run the project on your local machine for development and testing purposes.

Prerequisites

Make sure you have the following software installed on your machine:

  • Node.js
  • npm (Node Package Manager)

Installation

  1. Clone the repository to your local machine:

    git clone https://github.com/your-username/snake-game.git
    
  2. Navigate to the project directory:

cd snake-game
  1. Install the project dependencies:
npm install

Running the Game To start the game in development mode, run the following command:

npm start

Building for Production To build the app for production, run the following command:

npm run build

Project Structure

The project directory structure is as follows:

.env
.gitignore
.prettierignore
jsconfig.json
package.json
public/
    index.html
    manifest.json
    robots.txt
README.md
src/
    App.css
    App.js
    App.test.js
    classes/
        LinkedList.js
        Queue.js
    components/
        BoardCell/
            BoardCell.js
        GameBoard/
            GameBoard.js
        ScoreBoard/
            ScoreBoard.js
        SnakeHeader/
            SnakeHeader.js
    fonts/
        snake.ttf
    img/
    index.css
    index.js
    reportWebVitals.js
    setupTests.js
    sounds/
    utils.css