How sreenathkalluri/guessmate works
GuessMate is a browser-based, in-person party game: players authenticate anonymously, create or join a room, ready up, submit identity guesses, and see final standings. The app routes from room state to lobby, active game, or winner views; a shared context coordinates auth, room listening, and game actions. Firebase Auth and Firestore provide identity and real-time room state. README capability claims include security rules and offline/error handling; those are noted, but unsampled implementations and uncertain links are not expanded.
Main entry points: GameContext.jsx Shared game state · roomService.js Room lifecycle · auth.js Firebase Auth adapter · App.jsx App state router
Components 24
Game experience
- App state router
src/App.jsx - Create or join
src/pages/Home/Home.jsx - Ready lobby
src/pages/Lobby/Lobby.jsx - Live guessing
src/pages/Game/Game.jsx - Winner standings
src/pages/Winner/Winner.jsx - Guess search dialog
src/components/GuessModal.jsx - Player list
src/components/PlayerList.jsx - Scoreboards
src/components/Scoreboard.jsx
App coordination
- Shared game state
src/context/GameContext.jsx - Auth state hook
src/hooks/useAuth.js - Room sync hook
src/hooks/useRoom.js - Idle monitoring
src/hooks/useIdleTimer.js - Activity tracking
src/services/sessionService.js
Game services
- Room lifecycle
src/services/roomService.js - Game rules and scoring
src/services/gameService.js - Actor search and assignment
src/services/actorService.js - Actor dataset
src/data/actors.json - Room and name utilities
src/utils/session.js
Firebase infrastructure
- Firebase Auth adapter
src/firebase/auth.js - Firebase app config
src/firebase/config.js - Firestore adapter
src/firebase/firestore.js - Firestore
- Firebase Authentication
Other components
- Players
Connections 34
- Players → Create or join: create or join
src/pages/Home/Home.jsx - App state router → Shared game state: provides state
src/App.jsx - App state router → Create or join: routes to
src/App.jsx - App state router → Ready lobby: routes to
src/App.jsx - App state router → Live guessing: routes to
src/App.jsx - App state router → Winner standings: routes to
src/App.jsx - Create or join → Shared game state: requests room actions
src/pages/Home/Home.jsx - Shared game state → Auth state hook: reads auth state
src/context/GameContext.jsx - Shared game state → Room sync hook: subscribes to room
src/context/GameContext.jsx - Shared game state → Room lifecycle: dispatches room actions
src/context/GameContext.jsx - Shared game state → Game rules and scoring: dispatches game actions
src/context/GameContext.jsx - Auth state hook → Firebase Auth adapter: subscribes to auth
src/hooks/useAuth.js - Room sync hook → Room lifecycle: watches room
src/hooks/useRoom.js - Live guessing → Shared game state: submits guesses
src/pages/Game/Game.jsx - Live guessing → Guess search dialog: opens dialog
src/pages/Game/Game.jsx - Live guessing → Scoreboards: renders scores
src/pages/Game/Game.jsx - Winner standings → Scoreboards: renders standings
src/pages/Winner/Winner.jsx - Ready lobby → Player list: renders players
src/pages/Lobby/Lobby.jsx - Guess search dialog → Actor search and assignment: searches actors
src/components/GuessModal.jsx - Room lifecycle → Firestore adapter: reads and writes
src/services/roomService.js - Room lifecycle → Firebase Auth adapter: ensures identity
src/services/roomService.js - Room lifecycle → Room and name utilities: generates room code
src/services/roomService.js - Game rules and scoring → Firestore adapter: reads and writes
src/services/gameService.js - Game rules and scoring → Firebase Auth adapter: uses identity
src/services/gameService.js - Game rules and scoring → Actor search and assignment: assigns identities
src/services/gameService.js - Actor search and assignment → Actor dataset: loads dataset
src/services/actorService.js - Idle monitoring → Activity tracking: tracks activity
src/hooks/useIdleTimer.js - Activity tracking → Room lifecycle: removes idle player
src/services/sessionService.js - Activity tracking → Firestore adapter: updates activity
src/services/sessionService.js - Activity tracking → Firebase Auth adapter: ensures identity
src/services/sessionService.js - Firebase Auth adapter → Firebase app config: initializes auth
src/firebase/auth.js - Firestore adapter → Firebase app config: uses app config
src/firebase/firestore.js - Firebase Auth adapter → Firebase Authentication: authenticates anonymously
README.md - Firestore adapter → Firestore: stores room state
README.md