When writing async functions, there are differences between await
vs return
vs return await
, and picking the right one is important.
Netflix functions without client-side React, and it's a good thing
A few days ago Netflix tweeted that they'd removed client-side React.js from their landing page and they saw a 50% performance improvement. It caused a bit of a stir.
Lazy async SVG rasterisation
Using createImageBitmap
to make SVG render off the main thread.
HTTP/2 push is tougher than I thought
"HTTP/2 push will solve that" is something I've heard a lot when it comes to page load performance problems, but I didn't know much about it, so I decided to dig in.
HTTP/2 push is more complicated and low-level than I initially thought, but what really caught me off-guard is how inconsistent it is between browsers – I'd assumed it was a done deal & totally ready for production.
ECMAScript modules in browsers
ES modules are starting to land in browsers! Modules in general are pretty well documented, but here are some browser-specific differences…
Combining fonts
I love the font Just Another Hand, but I don't like the positioning of the hyphen & equals glyphs. Thankfully I can use CSS fonts to fix it!
Async iterators and generators
Async iterators are arriving soon, and they make reading a stream really easy. Here's how they work, and how to make streams iterate…
Do we need a new heading element? We don't know
There's a proposal for adding a new <h>
element to the HTML spec, but can we solve the problem in a way that benefits the existing web?
Events and disabled form fields
Turns out, mouse events don't fire when the pointer is over disabled form elements, except in Firefox. This is annoying when implementing things like drag & drop.
Fun hacks for faster content
A few weeks ago I was at Heathrow airport getting a bit of work done before a flight, and I noticed something odd about the performance of GitHub: It was quicker to open links in a new window than simply click them. Turns out it was a lack of streaming…