AshishGusain17 / chesslive365

A chess website where you can challenge your friends for a 2-player match without logging in or any verification. All other persons with the access to the game-link can view the game live.

Home Page:https://chesslive365.herokuapp.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Chesslive365

A chess website where you can challenge your friends for a 2-player match without logging in or any verification.
Also, all other persons with the access to the game-link can view the game live.
Visit: https://chesslive365.herokuapp.com/

Click on the video link below to see the working of this app:

Click here

UI in mobile & desktop

You can play in desktop as well as from your mobile devices. Screenshots of both the versions are attached below:

Dependencies required:

Features:

1.) Challenge your friends for a 2-player match without logging in or any verification.
2.) All other persons with the access to the game-link can view the game live.
3.) You can play with both the pieces by yourself in home-page.
4.) Reverse board, change box colors, 5 different pieces(like metal, gothic, graffiti) are available.

Changes while working locally:

FilePath: backend/package.json/
Change scripts as below:
"start": "nodemon index.js"

FilePath: src/context/position/PositionState.js/ 
change HOST variable value to REACT_APP_BACKEND_LOCALHOST

Create a .env file inside root folder and provide following env variable:
REACT_APP_BACKEND_LOCALHOST = 'http://localhost:5000'

Create a .env file inside backend folder too and provide following env variables:
MONGO_URL 
PORT = 5000

Changes while deploying:

FilePath: backend/package.json/ 
Change scripts as below:
"start": "node index.js"

FilePath: src/context/position/PositionState.js/
change HOST variable value to REACT_APP_BACKEND_HOST

Create a .env file inside root folder and provide following env variable:
REACT_APP_BACKEND_HOST = <end_point_url>

Create a .env file inside backend folder too and provide following env variables:
MONGO_URL 
PORT = 5000

SELF NOTE:

1.) Changes in files in backend folder:
app.listen(process.env.PORT || '0.0.0.0' );
from gitbash : touch Procfile   ==>  web: node index.js  ==>  scripts:{"start": "node index.js"}

2.) Update config vars in heroku settings for environment variables 
in both frontend and backend

3.) While deploying, since backend folder is already inside a git repo, we cannot
directly push it. 
So, copy backend files(except node_modules and .env) in some non-git folder(Assume FOLDER_NAME = 'chesslive365api') 
and follow below steps:


cd chesslive365api
git init
git remote add heroku  https://git.heroku.com/chesslive365api.git
git add .
git commit -am "make it better"
git push heroku main --force

About

A chess website where you can challenge your friends for a 2-player match without logging in or any verification. All other persons with the access to the game-link can view the game live.

https://chesslive365.herokuapp.com/


Languages

Language:JavaScript 87.6%Language:CSS 9.0%Language:HTML 3.1%Language:Python 0.3%