Skip to content

yassine20011/chess-app

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

chess-app

Introduction

The idea behind this project is to create a chess game that can be played by two players. The game will be implemented using Laravel and React.js, along with Inertia.js. if unfamiliar with inertia.js is, you can find more information about it here.

I am creating this project, first of all, because I love playing chess. Second, I want to learn more about Laravel and explore Websockets. I'll be using Laravel broadcasting to implement the game's real-time functionality, and I will use react.js just because I am used to it.

The first move ♟️ is to create a conceptual plan for the project. The conception can be found in the diagrams folder.

What is inertia.js?

Inertia.js lets you quickly build modern single-page React, Vue, and Svelte apps using classic server-side routing and controllers. It provides the best of both worlds by combining the simplicity of classic server-driven apps with the performance of single-page apps.

If you are reading this and you want to test the project, you can clone the project and run the following commands:

git clone https://github.com/yassine20011/chess-app.git

Then you need to install the dependencies:

composer install
npm install

Then you need to create a .env file and add the following content:

cp .env.example .env

You will find a docker-compose file in the project, you can use it to run postgresql database, you can run the following command to start the database:

docker compose up -d

Then you need to run the migrations:

php artisan migrate

Then you can run the project using the following command:

php artisan serve

You are not done yet, you need to run the following commands to start the websockets server and the queue listener:

php artisan reverb:start
# and open a new terminal and run the following command
php artisan queue:listen
# finally open a new terminal and run the following command
npm run dev

alt text

Contributing

Contributions are welcome! To contribute:

  1. Fork the repository.
  2. Create a new branch for your feature or bug fix.
git checkout -b feature/your-feature
  1. Make your changes and commit them.
git commit -m 'Add some feature'
  1. Push to the branch.
git push origin feature/your-feature
  1. Open a pull request 🎉

About

The Chess App is a web application that allows users to play chess in real-time. It supports multiplayer games, user authentication.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages