Implement real-time presence tracking with PubNub
96
67%
Does it follow best practices?
Impact
100%
1.33xAverage score across 20 eval scenarios
Advisory
Suggest reviewing before use
A remote-first company wants a team availability dashboard that shows each team member's current status (available, busy, in a meeting, away) across all their devices. When someone updates their status on their phone, it should reflect immediately on the desktop dashboard. When someone closes all their browser tabs or their connection drops, they should show as offline. The dashboard is built as a single-page web application.
The company uses PubNub and each team has a channel (e.g., team-{teamId}). They need the client-side code that:
Build the client-side JavaScript module for this dashboard.
Produce a file called availability-dashboard.js containing:
Also produce a file called setup-notes.md that documents: