MCPcopy Index your code
hub / github.com/code100x/chess

github.com/code100x/chess @main

Chat with this repo
repository ↗ · DeepWiki ↗ · + Follow
145 symbols 441 edges 114 files 0 documented · 0%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Chess

Building a platform where people can

  1. Sign up
  2. Create a new match/get connected to an existing match
  3. During the match, let users play moves
  4. Have a rating system that goes up and down similar to standard chess rating

Tech stack

Let's keep it simple

  1. React for Frontend
  2. Node.js for Backend
  3. Typescript as the language
  4. Separate Websocket servers for handling real time games
  5. Redis for storing all moves of a game in a queue

Setting it up locally

  • Clone the repo
  • Copy over .env.example over to .env everywhere
  • Update .env
    • Postgres DB Credentials
    • Github/Google Auth credentials
  • npm install
  • Start ws server
    • cd apps/ws
    • npm run dev
  • Start Backend
    • cd apps/backend
    • npm run dev
  • Start frontend
    • cd apps/frontend
    • npm run dev

Extension points exported contracts — how you extend this code

User (Interface)
(no doc)
packages/store/src/atoms/user.ts
ButtonProps (Interface)
(no doc)
packages/ui/src/button.tsx
GameModeComponent (Interface)
(no doc)
apps/frontend/src/components/GameModeComponent.tsx
GithubEmailRes (Interface)
(no doc)
apps/backend/src/passport.ts
BaseProps (Interface)
(no doc)
apps/native/components/chessboard/components/chessboard-background.tsx
userJwtClaims (Interface)
(no doc)
apps/ws/src/auth/index.ts
PlayerTitleProps (Interface)
(no doc)
apps/frontend/src/components/PlayerTitle.tsx
userJwtClaims (Interface)
(no doc)
apps/backend/src/router/auth.ts

Core symbols most depended-on inside this repo

cn
called by 34
apps/frontend/src/lib/utils.ts
useChessboardProps
called by 13
apps/native/components/chessboard/context/props-context/hooks.ts
useReversePiecePosition
called by 5
apps/native/components/chessboard/notation.ts
useChessEngine
called by 5
apps/native/components/chessboard/context/chess-engine-context/hooks.ts
broadcast
called by 5
apps/ws/src/SocketManager.ts
addUser
called by 5
apps/ws/src/GameManager.ts
useUser
called by 4
packages/store/src/hooks/useUser.ts
endGame
called by 4
apps/ws/src/Game.ts

Shape

Function 88
Method 26
Interface 22
Class 8
Enum 1

Languages

TypeScript100%

Modules by API surface

apps/ws/src/Game.ts18 symbols
apps/ws/src/SocketManager.ts10 symbols
apps/ws/src/GameManager.ts7 symbols
apps/frontend/src/screens/Game.tsx7 symbols
apps/frontend/src/components/GameEndModal.tsx6 symbols
apps/frontend/src/components/ChessBoard.tsx6 symbols
apps/frontend/src/screens/Login.tsx4 symbols
apps/native/components/chessboard/components/chessboard-background.tsx3 symbols
apps/native/app/game/index.tsx3 symbols
apps/frontend/src/utils/canvas.ts3 symbols
apps/frontend/src/components/ui/sheet.tsx3 symbols
apps/frontend/src/components/sidebar.tsx3 symbols

For agents

$ claude mcp add chess \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact