Due to complexity, missing features, and browser bugs, I don't think I'd recommend HTTP/2-push to anyone unless they'd exhausted all other optimisations (including link[rel=preload]), and have a large expert team to deal with the fallout.https://jakearchibald.com/2017/h2-push-tougher-than-i-thought/ …
-
-
It does everything short of executing it.
-
So close! So close!
-
If it also executed, what would be the difference between it and <script type="module">?
-
It would allow you to fetch a graph of modules (with names) in order from leaves, and execute the leaves as they come. Today, if you have a -> b -> c and you push c, b, then a, you still have to wait for a to evaluate c, because top import in a is what kicks off eval.
-
In a large graph, this means that you can't start executing at all until you have an entire subgraph starting from the root, which is deeply suboptimal compared to topsorting the modules and evalling the leaves upward.
-
Suboptimal as in: you would notice this in a big way.
-
To check we're on the same page, you're saying that: If 'c' changes the background color of body to red, you'd expect the bg to become red if <link rel=modulepreload href=a>?
-
I'm saying that yes, but (1) maybe modulepreeval, and (2) not because I want that side effect, but just to allow interleaving of fetch/eval and control latency.
- 1 more reply
New conversation -
-
-
But this is another reason that a small lib written on top of lower level primitives might be better. Frustratingly, people pouring their hopes and dreams into H2 for years has detailed a lot of reasonable concurrent progress (like web archive)
Thanks. Twitter will use this to make your timeline better. UndoUndo
-
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.