Auto-Sizing Textarea

By Chris Coyier on

Credit to Stephen Shaw for the original idea, there is a decently easy way to make an auto-sizing <textarea> element. It is here. But it’s not perfect. There is a frustrating hard-to-replicate iOS bug. Plus it’s just a trick. It requires JavaScript and some pretty specific CSS to pull off. It’s awesome to see the […]

The Popular Vote of Interop 2024

By Chris Coyier on

I believe it will be sometime in January we’ll hear what the Interop Project is going to focus on in 2024. This is a cross-company effort that picks certain web platform features to make sure work perfectly across browsers, meaning us web developers will more happily choose to implement them. I think it’s awesome. We’ve […]

Still No CSS Reset

By Chris Coyier on

Happy New Year ya’ll! While we’re all thinking about taking the opportunity to do various resets on our lives, I’ll take the opportunity to mention CSS resets. As a CSS nerd, I love looking at people’s different takes on what a modern CSS reset could or should be, like I did recently. But that doesn’t […]

Vertical Centering in a Block-Level Element

By Chris Coyier on

Rachel Andrew, blowing my mind a bit: The align-content property from the Box Alignment spec does the job, however browsers require that you make the parent element either a flex or a grid layout. While the property was specified to work in block layout, no browser had implemented it, until now. align-content in block layout So now […]

🚫 Multiple Selects

By Chris Coyier on

A good point by Mayank: The multiple attribute on <select> should pretty much never be used. It’s like the polar opposite of single <select>, where instead of universal familiarity, it has universal unfamiliarity. Perhaps its only saving grace is that I have yet to encounter this attribute in any codebase. HTML: The Bad Parts

Date-based styles with :has()

By Chris Coyier on

We just looked at how :has() in CSS makes quantity queries so easy, so this post by Terence Eden caught my eye, showing some trickery where you can style an entire page based on when it was published. That is, if there is something like a <time> or <meta> tag that has this information on […]

@media (scripting: enabled)

By Chris Coyier on

Ahmad Shadeed: Today I learned about the media scripting feature. It’s about detecting JS support via a CSS media query. Soon, we won’t need the .no-js or .js classes once this is widely available. Currently supported in Chrome 120, Firefox 119, Safari 17. Tweet