How polkboban/teamsync works
TeamSync is a real-time collaborative project-management workspace. Users register or sign in, enter workspaces and boards, manage lists and tasks, and collaborate through comments, checklists, presence, and notifications. The graph follows the documented route and task flows; workspace and board API details are only partly sampled, so uncertain client-to-server links are omitted. PostgreSQL, Redis, and Socket.IO capabilities are documented in the README, but not every implementation detail is shown.
Main entry points: App.tsx Route shell · BoardPage.tsx Board workspace · auth.ts Token authentication · index.ts Express route registration
Components 25
Web application
- Route shell
frontend/src/App.tsx - Session context
frontend/src/context/AuthContext.tsx - Sign-in and registration
frontend/src/pages/LoginPage.tsx - Landing page
frontend/src/pages/LandingPage.tsx - Command palette
frontend/src/components/CommandPalette.tsx - HTTP client
frontend/src/api/client.ts
Workspace and tasks
- Workspace directory
frontend/src/pages/WorkspacesPage.tsx - Board workspace
frontend/src/pages/BoardPage.tsx - Task inspector
frontend/src/components/TaskDetailsDrawer.tsx - Task API client
frontend/src/api/tasks.ts - Workspace handlers
ts-backend/src/controllers/workspaceController.ts - Task handlers
ts-backend/src/controllers/taskController.ts
API and identity
- Express route registration
ts-backend/src/index.ts - Authentication routes
ts-backend/src/routes/authRoutes.ts - Workspace routes
ts-backend/src/routes/workspaceRoutes.ts - Task routes
ts-backend/src/routes/taskRoutes.ts - Authentication handlers
ts-backend/src/controllers/authController.ts - Token authentication
ts-backend/src/middleware/auth.ts - JWT utilities
ts-backend/src/utils/jwt.ts
Live collaboration
- Socket context
frontend/src/context/SocketContext.tsx - Socket server
ts-backend/src/socket.ts - Redis connection
ts-backend/src/config/redis.ts
Other components
- Team member
- PostgreSQL database
- Redis Pub/Sub and cache
Connections 30
- Team member → Route shell: uses
- Route shell → Session context: provides
frontend/src/App.tsx - Route shell → Sign-in and registration: routes
frontend/src/App.tsx - Route shell → Landing page: routes
frontend/src/App.tsx - Route shell → Workspace directory: routes
frontend/src/App.tsx - Route shell → Board workspace: routes
frontend/src/App.tsx - Sign-in and registration → Session context: calls
frontend/src/pages/LoginPage.tsx - Board workspace → Task API client: calls
frontend/src/pages/BoardPage.tsx - Board workspace → Task inspector: renders
frontend/src/pages/BoardPage.tsx - Board workspace → Command palette: renders
frontend/src/pages/BoardPage.tsx - Task inspector → Task API client: calls
frontend/src/components/TaskDetailsDrawer.tsx - Task API client → HTTP client: sends requests
frontend/src/api/tasks.ts - Route shell → Socket context: provides
frontend/src/App.tsx - Express route registration → Authentication routes: mounts
ts-backend/src/index.ts - Express route registration → Workspace routes: mounts
ts-backend/src/index.ts - Express route registration → Task routes: mounts
ts-backend/src/index.ts - Authentication routes → Authentication handlers: dispatches
ts-backend/src/routes/authRoutes.ts - Workspace routes → Workspace handlers: dispatches
ts-backend/src/routes/workspaceRoutes.ts - Task routes → Task handlers: dispatches
ts-backend/src/routes/taskRoutes.ts - Authentication routes → Token authentication: authenticates
ts-backend/src/routes/authRoutes.ts - Workspace routes → Token authentication: authenticates
ts-backend/src/routes/workspaceRoutes.ts - Task routes → Token authentication: authenticates
ts-backend/src/routes/taskRoutes.ts - Token authentication → JWT utilities: verifies token
ts-backend/src/middleware/auth.ts - Task handlers → PostgreSQL database: reads and writes
ts-backend/src/controllers/taskController.ts - Workspace handlers → PostgreSQL database: reads and writes
ts-backend/src/controllers/workspaceController.ts - Workspace handlers → Redis connection: uses
ts-backend/src/controllers/workspaceController.ts - Redis connection → Redis Pub/Sub and cache: connects
ts-backend/src/config/redis.ts - Task handlers → Socket server: emits updates
ts-backend/src/controllers/taskController.ts - Socket context → Socket server: exchanges events
- Socket server → Redis connection: uses
ts-backend/src/socket.ts