←back to thread

170 points bko | 1 comments | | HN request time: 0.357s | source
Show context
mike_ivanov ◴[] No.43650803[source]
But.. SSE is limited to like 6 or so connections per browser, no?
replies(3): >>43651111 #>>43651444 #>>43651531 #
1. andersmurphy ◴[] No.43651531[source]
I'd also add even if for whatever reason you are on http1.1 (you should really use http2 for server driven apps there's a lot of other advantages). Datastar prunes connection based on the browser visibility API so on http1.1 a user would need 5-6 visible tabs/windows visible at the same time for you to hit any issues.

Assuming you are using Datastar the way I do with a single persistent SSE connection.

This feature is also much better for the battery life of devices and the server as you are only sending stuff if the user is there.