Loading video...

Video Failed to Load

Go Home

auto-growing <textarea> without JavaScript! CSS is getting field-sizing: content; to size inputs by their contents. Dropped in Chrome Canary today, demo here:

203,517 views • 2 years ago •via X (Twitter)

9 Comments

Cory House's profile picture
Cory House2 years ago

Wow Wes I really like this video format. Super clear and mobile friendly. 👍

Wes Bos's profile picture
Wes Bos2 years ago

thanks a ton! Been about a year of playing with different layouts. It lends itself well to quick little tips without a ton of code

Wes Bos's profile picture
Wes Bos2 years ago

yeah! @stolinski used the popover API for do them on our site - and then I just used links

Jason's profile picture
Jason2 years ago

And people say CSS isn’t a real language. It’s magical

Kilian Valkhof's profile picture
Kilian Valkhof2 years ago

Impressive turnaround time there 😁 Also available in Polypane 17, released today 😎

Martin Elitzer's profile picture
Martin Elitzer2 years ago

Most awesome new css feature I've seen in a minute.

ELLIOT's profile picture
ELLIOT2 years ago

Woah, that would be so awesome. I had to deal with input auto-sizing a few days ago, and there literally was just horrible ways of doing it.

Rik Schennink's profile picture
Rik Schennink2 years ago

Nice! Hassle to do with JS. Could this, instead of introducing a new property, also work with: width: fit-content; height: fit-content; Haven’t tested but seems it should do the same?

Wes Bos's profile picture
Wes Bos2 years ago

Apparently it was considered, but not the exact same thing:

Related Videos