{"id":22671847,"url":"https://github.com/jesuisstan/tetris-game","last_synced_at":"2025-03-29T11:23:09.503Z","repository":{"id":208312882,"uuid":"721326164","full_name":"jesuisstan/tetris-game","owner":"jesuisstan","description":null,"archived":false,"fork":false,"pushed_at":"2024-04-10T01:16:23.000Z","size":1300,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-04-11T03:06:02.662Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jesuisstan.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2023-11-20T20:35:42.000Z","updated_at":"2024-04-14T18:39:22.134Z","dependencies_parsed_at":"2024-02-18T21:27:16.298Z","dependency_job_id":"6f10ec80-8bbf-4c6b-a2c7-ca8384cb1771","html_url":"https://github.com/jesuisstan/tetris-game","commit_stats":null,"previous_names":["jesuisstan/tetris-game"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jesuisstan%2Ftetris-game","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jesuisstan%2Ftetris-game/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jesuisstan%2Ftetris-game/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jesuisstan%2Ftetris-game/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jesuisstan","download_url":"https://codeload.github.com/jesuisstan/tetris-game/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246175656,"owners_count":20735608,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-12-09T16:16:54.270Z","updated_at":"2025-03-29T11:23:09.477Z","avatar_url":"https://github.com/jesuisstan.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Project Documentation: Tetris Game Fullstack App\r\n\r\n## Objective\r\n\r\nThe primary goal of this project was to develop a full-stack tetris multiplayer game\r\n\r\n## Implementation\r\n\r\nThe project was implemented using functional components and popular hooks in ReactJS with JavaScript and [Create React App](https://facebook.github.io/create-react-app/docs/getting-started), leveraging the Material UI library for its components and styling, in addition to custom CSS modules. The App was developed to be responsive, following a multi-platform approach. The following steps were taken to complete the project:\r\n\r\n1.  **Backend + MongoDB implementation**: Backend was built with Node.js (express). Database (MongoDB) was attached to backend to store all user accounts data. Authentication (sign up and sign in) with user's email and password (encrypted) is also implemented.\r\n\r\n2.  **Frontend**: Front part of the application was build with React library for Javascript, using React Router and Redux to store the application states.\r\n\r\n3.  **Material UI, Custom Styling with CSS Modules \u0026 Custom Fonts**: Material UI components were utilized to achieve a consistent and visually appealing design. Components such as TextField, Drawer, LoadingButton and others were used to create responsive and user-friendly web-app and related elements. The Google font was applied to the project to improve attractiveness of the App.\r\n\r\n4.  **Socket**: The communication between the server and the clients is bi-directional, Socket.io is used for the implementation.\r\n\r\n5.  **Version Control**: The code was hosted on GitHub and made publicly accessible. The repository can be found at https://github.com/jesuisstan/tetris-game.\r\n\r\n6.  **Testing**: Increase the reliability of the delivered versions, Jest is used as a tool for unit testing. Covered at least 70% of the statements, functions, lines and at least 50% of the branches.\r\n\r\n7.  **Deployment**: Not yet\r\n\r\n## Results\r\n\r\nDeployed version of the App allows user to:\r\n\r\n- authenticate with email and password (create new account or login to existing one). To test the App a user can click the button \"Test\" on authentication page;\r\n\r\n- ...\r\n\r\n## Demonstration\r\n\r\n## How to use\r\n\r\n##### 1. Install general dependencies (JS, package manager, etc):\r\n\r\n- install Node version manager (nvm):\r\n\r\n```sh\r\nsudo apt install curl\r\n```\r\n\r\n```sh\r\ncurl https://raw.githubusercontent.com/creationix/nvm/master/install.sh | bash\r\n```\r\n\r\n```sh\r\nsource ~/.profile\r\n```\r\n\r\nrestart terminal\r\n\r\n- install NodeJS:\r\n\r\n```sh\r\nnvm install node\r\n```\r\n\r\n- install Node package manager (npm):\r\n\r\n```sh\r\nnpm install -g npm@latest\r\n```\r\n\r\n##### 2. Adjust .env file if you need other HOST, PORT, MONGO variables.\r\n\r\n##### 3. Run the App:\r\n\r\na) with Docker:\r\n\r\n- run docker compose project:\r\n\r\n```sh\r\ndocker compose up\r\n```\r\n\r\nOR\r\n\r\nb) with NPM:\r\n\r\n- install all the application dependencies according to 'package.json' files from the root, /frontend \u0026 /backend dirs:\r\n\r\n```sh\r\nnpm run install:all\r\n```\r\n\r\n- Start Tetris App:\r\n\r\nin development mode:\r\n\r\n```sh\r\nnpm run dev\r\n```\r\n\r\nin production mode:\r\n\r\n```sh\r\nnpm start\r\n```\r\n\r\n##### 4. Open the App link in browser ([http://localhost:4040](http://localhost:4040) by default).\r\n\r\n##### 5. Additional commands:\r\n\r\n- to list all Docker container:\r\n\r\n```sh\r\ndocker ps -a\r\n```\r\n\r\n- to list all Docker images:\r\n\r\n```sh\r\ndocker images\r\n```\r\n\r\n- to stop all running containers:\r\n\r\n```sh\r\ndocker stop $(docker ps -q)\r\n```\r\n\r\n- to remove all stopped containers:\r\n\r\n```sh\r\ndocker rm $(docker ps -a -q)\r\n```\r\n\r\n- to delete all Docker images\r\n\r\n```sh\r\ndocker rmi $(docker images -q)\r\n```\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjesuisstan%2Ftetris-game","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjesuisstan%2Ftetris-game","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjesuisstan%2Ftetris-game/lists"}