January 7, 2023

When I was on Alex Trost’s holiday stream, real quick at the end, I showed a way that CSS can animate to auto dimensions. This is a hell of a trick and it’s pretty great there is a way to get it done in without needing JavaScript to measure things ahead of time. Ideally, CSS would just… let us do this without any trickery.

I mentioned this again in Things CSS Could Still Use Heading Into 2023.

I didn’t discover the (extremely cool) trick for doing it today though. That was discovered by Nelson Menezes back in October 2021. I saw his article then blogged it on CSS-Tricks a week later. It has started working in Chrome and Safari since then, which is nice, but again, CSS should just allow auto transitions and animations.

Just wanted to make sure the history is correct, as I’ve seen a new round of excitement over knowing this is possible today.

🤘

ncG1vNJzZmibmKe2tK%2FOsqCeql6jsrV7kWlpbGdgZnxxg46iZJ2hlKPBbrDIrJqorpWnerW0wK1koKqZmXq1scypo5qslWK%2FsMPSZquroZOgeqe70WaYp6GdlsGqusZmq6hlkarBsHnIp2Scq6Niwamt02aumqtdo7Ktv86nZKadnprHpr%2BO