News for hackers. Stuff that matters.
Re:JavaScript import maps are now supported cross-browser by deathanatos on Wednesday May 03, 2023 @03:07PM (#35806399)
> HTTP2/3 […] but does not change the limit of max concurrency imposed by the browser.

No. HTTP/2 is allowed far more than 6 requests at a time; within a single connection it's limited by the max concurrent streams setting in the SETTINGS frame and the browser's willingness to take advantage of it; AIUI, e.g., in Firefox, that limit is 100.[1]

From there, you're limited by connection bandwidth and any brief HoL blocking caused by dropped packets (but not by HoL blocking caused at the server).

[1]: https://stackoverflow.com/questions/36835972/is-the-per-host...

Re:JavaScript import maps are now supported cross-browser by e1g on Wednesday May 03, 2023 @04:06PM (#35807058)
You might be right, and my initial assessment is incorrect. The real reason why HTTP2 doesn't solve the loading problem with many files is the depth of imports across all dependencies - the browser loads the entry file, sees its imports, fetches those URLs, then discovers new imports, starts fetching those, discovers more, etc recursively. So the slowness is caused by the latency of each round trip (easily 50ms-500ms), and not by how many files the browser has in-flight simultaneously, as I assumed.