Hacker News new | ask | show | jobs
Show HN: Shared EventSource (github.com)
1 points by monssoen 305 days ago
To get around the browser maximum limit of 6 SSE connections per domain (eg. on localhost) I created a very small library which forwards one EventSource to all tabs and workers using a BroadcastChannel. A leader is selected using the Web Locks API. It has the same API as a regular EventSource.