{"id":25531662,"url":"https://github.com/ore-codes/typeshii","last_synced_at":"2026-02-15T01:05:22.248Z","repository":{"id":278351351,"uuid":"935316199","full_name":"ore-codes/typeshii","owner":"ore-codes","description":"TypeShii– A fast-paced multiplayer typing racing game built with NestJS, React (Vite), Socket.IO, and Redis, managed in a Turborepo monorepo","archived":false,"fork":false,"pushed_at":"2025-02-19T09:31:29.000Z","size":7660,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-05-22T10:56:51.030Z","etag":null,"topics":["game","motion-react","multiplayer","redis","rxjs","socket-io"],"latest_commit_sha":null,"homepage":"https://typeshii-ruddy.vercel.app","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ore-codes.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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,"publiccode":null,"codemeta":null}},"created_at":"2025-02-19T08:49:18.000Z","updated_at":"2025-02-19T09:31:32.000Z","dependencies_parsed_at":"2025-02-19T10:41:15.770Z","dependency_job_id":null,"html_url":"https://github.com/ore-codes/typeshii","commit_stats":null,"previous_names":["ore-codes/typeshii"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ore-codes/typeshii","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ore-codes%2Ftypeshii","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ore-codes%2Ftypeshii/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ore-codes%2Ftypeshii/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ore-codes%2Ftypeshii/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ore-codes","download_url":"https://codeload.github.com/ore-codes/typeshii/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ore-codes%2Ftypeshii/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29463601,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-15T01:01:38.065Z","status":"ssl_error","status_checked_at":"2026-02-15T01:01:23.809Z","response_time":53,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["game","motion-react","multiplayer","redis","rxjs","socket-io"],"created_at":"2025-02-20T01:19:26.171Z","updated_at":"2026-02-15T01:05:22.219Z","avatar_url":"https://github.com/ore-codes.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# TypeShii Monorepo\n\nWelcome to **TypeShii**, a fast-paced multiplayer typing racing game built as part of a take-home assessment for a job application. This monorepo is managed using **Turborepo** and contains both the frontend and backend for the game.\n\n## 🎮 About the Game\n\nTypeShii is a multiplayer game where players compete to type through a given paragraph as quickly and accurately as possible. The first player to complete the paragraph wins!\n\n### How to Play\n1. **Join or Create a Game**:\n   - Enter an existing game ID or create a new game.\n2. **Race to Type**:\n   - Type the provided paragraph as quickly and accurately as possible.\n   - Progress is displayed in real-time for all players.\n3. **Win**:\n   - The first player to complete the paragraph is the winner, but all players can see their scores and rankings at the end.\n\n---\n\n## 🛠️ Technologies Used\n\n### Frontend (apps/web)\n- **[RxJS](https://rxjs.dev/)**: For reactive state management and handling real-time updates efficiently.\n- **[Storybook](https://storybook.js.org/)**: For building and testing UI components in isolation.\n- **[Framer Motion](https://www.framer.com/motion/)**: For smooth animations and transitions.\n- **[Vite](https://vitejs.dev/)**: A fast and modern frontend build tool.\n- **[Socket.IO](https://socket.io/)**: For real-time communication between the client and server.\n\n### Backend (apps/server)\n- **[Node.js](https://nodejs.org/)**: Runtime for building server-side applications.\n- **[NestJS](https://nestjs.com/)**: Framework for scalable and modular backend systems.\n- **[Socket.IO](https://socket.io/)**: Library for real-time bidirectional communication.\n- **[RxJS](https://rxjs.dev/)**: Reactive programming for efficient handling of data streams.\n- **[Redis](https://redis.io/)**: In-memory data store for fast state management.\n- **[Jest](https://jestjs.io/)**: For end-to-end testing.\n\n---\n\n## 🚀 Getting Started\n\nFollow these steps to set up and run the project locally:\n\n### Prerequisites\nMake sure you have the following installed:\n- **Node.js** (v16 or later)\n- **npm** (preferred dependency manager)\n\n### Installation\n\n1. **Clone the Repository**\n   ```bash\n   git clone https://github.com/ore-codes/typeshii.git\n   cd typeshii\n   ```  \n\n2. **Install Dependencies**\n   ```bash\n   npm install\n   ```  \n\n3. **Set Up Environment Variables**  \n   Create a `.env` file in the root directory with the following content:\n   ```env\n   # Backend\n   PORT=3000\n   REDIS_URL=redis://localhost:6379\n   \n   # Frontend\n   VITE_SERVER_URL=http://localhost:3000\n   ```  \n   Replace values as needed based on your setup.\n\n4. **Run the Development Servers**\n   ```bash\n   npm run dev\n   ```  \n   This will start both the frontend and backend in parallel.\n\n5. **Run Storybook**\n   ```bash\n   npm run storybook --workspace=apps/web\n   ```  \n   Storybook will be accessible at `http://localhost:6006`.\n\n---\n\n## 🌟 Features\n\n- **Real-Time Multiplayer**: Powered by Socket.IO for seamless interactions between players.\n- **Reactive UI**: Built using RxJS to handle live updates in player progress and game states.\n- **Interactive Animations**: Framer Motion makes the game visually engaging and smooth.\n- **Component Isolation**: Storybook ensures high-quality, reusable UI components.\n- **Modern Build Tooling**: Vite and Turborepo enable efficient development and builds.\n- **Scalable Backend**: NestJS and Redis provide a solid foundation for real-time gameplay.\n\n---\n\n## 📂 Monorepo Structure\n\n```\ntypeshii/\n├── apps/\n│   ├── web/        # Frontend (React + Vite)\n│   ├── server/     # Backend (NestJS + Socket.IO)\n├── package.json    # Turborepo root package\n├── turbo.json      # Turborepo configuration\n```\n\n---\n\n## 🧩 Backend API Documentation\n\nThe backend provides WebSocket APIs for game interactions and REST APIs for auxiliary operations.\n\n### WebSocket Endpoints\n- **`createGame`** - Create a new game session.\n- **`joinGame`** - Join an existing game.\n- **`updateProgress`** - Update the player's progress.\n- **`leaveGame`** - Leave the current game.\n\n### WebSocket Events\n- **`gameJoined`** - Triggered when a player successfully joins a game.\n- **`gameStarted`** - Triggered when the game starts.\n- **`playerJoined`** - Triggered when a new player joins the game.\n- **`playerLeft`** - Triggered when a player leaves the game.\n- **`gameStateUpdated`** - Triggered when the game state updates.\n- **`gameCompleted`** - Triggered when the leaderboard is ready.\n- **`error`** - Triggered when an error occurs.\n\n### API Types\n```ts\nexport type Player = {\n   id: string;\n   progress: number;\n   speed: number;\n   typedText: string;\n   paragraph: string;\n   finishTime?: number;\n   score?: number;\n};\n```\n\n---\n\n## 🌐 Deployment\n\n1. Ensure the environment variables are properly configured on the production server.\n2. Use a process manager like **PM2** or Docker for deployment.\n3. Build and start the application:\n   ```bash\n   npm run build\n   npm run start\n   ```\n\n---\n\n## 🤝 Contributing\n\nContributions are welcome! Please fork the repository and submit a pull request.\n\n---\n\n## 📄 License\n\nThis project is licensed under the [MIT License](LICENSE).\n\n---\n\n## 🔗 Links\n\n- **Live Site**: [https://typeshii-ruddy.vercel.app/](https://typeshii-ruddy.vercel.app/)\n- **Storybook**: [https://67b5a18e3e293979dd71095d-akbfebirsz.chromatic.com/](https://67b5a18e3e293979dd71095d-akbfebirsz.chromatic.com/)\n\n---\n\nThank you for checking out **TypeShii**! 🚀\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fore-codes%2Ftypeshii","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fore-codes%2Ftypeshii","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fore-codes%2Ftypeshii/lists"}