IntersectionObserver to lazy load images—very handy for webmention avatars.
Here’s a really smart approach to creating container queries today—it uses
ResizeObserver to ensure that listening for size changes is nice and performant.
There’s a demo site you can play around with to see it in action.
While the strategy I outline in this post is production-ready, I see us as being still very much in the early stages of this space. As the web development community starts shifting its component design from viewport or device-oriented to container-oriented, I’m excited to see what possibilities and best practices emerge.
Bad Science » Madeleine McCann, the Observer, and their special magic quantum DNA box (with secret energy source)
I've said it before and I'll say it again: the Bad Science blog deserves a medal.