Live data from Hacker News

State of CSS

web.dev

1–10 of 234 posts

Re: State of CSS

#2
Great overview. I'm always excited by newer features to CSS that make older JS-only methods obsolete. I've also grown CSS-tooling fatigued after using SASS and PostCSS plugins for years. I've recently gone back to only using vanilla CSS on personal projects and while there are niceties I do miss (nesting) it's refreshing not having to deal with config files or waiting for stuff to compile.

Re: State of CSS

#3
Does anyone else feel like CSS has jumped the shark a bit?

https://web.dev/state-of-css-2022/#accent-color

Sure it's a "nice to have" but it bloats the spec? Look at the current actual implementation:

https://web.dev/accent-color/#guaranteeing-contrast

chrome and firefox already tint differently...

How is this better than a good ol CSS variable and leaving it up to the designer to manage?

Sure http://dowebsitesneedtolookexactlythesameineverybrowser.com/ but when the exec is like "why is our brand color slightly different on ff vs. chrome... we are back to square one.

Re: State of CSS

#4
Make no mistake: dialog element is there only because browsers (and Chrome, first and formost) want to remove alert/prompt.

dialog was so problematic that the same people that are now promoting it were in favor of removing it entirely. Literally none of the issues were solved, but now it's a great new element that we all should use.

Re: State of CSS

#6
I think I don't need the 2022 version, but the 2021 version. Or even the 2012 version, lol!

I still prefer to use tables to layout my websites.

Question: Say I want a layout that has a top row, a middle row and a bottom row. Each row gets 33% of the screen space. Unless the content does not fit. Then the row should expand to the content.

Here is the table version:

https://jsfiddle.net/vg2ey8r9/

How do you do that without a table?

Re: State of CSS

#7

Great overview. I'm always excited by newer features to CSS that make older JS-only methods obsolete. I've also grown CSS-tooling fatigued after using SASS and PostCSS plugins for years. I've recently gone back to only using vanilla CSS on personal projects and while there are niceties I do miss (nesting) it's refreshing not having to deal with config files or waiting for stuff to compile.

Actual nesting is on the way [0], but for now you can already use :is() [1] in many cases.

[0]: https://blog.openreplay.com/modern-css-selectors/

[1]: https://developer.mozilla.org/en-US/docs/Web/CSS/:is

Re: State of CSS

#8
post #3

Does anyone else feel like CSS has jumped the shark a bit? https://web.dev/state-of-css-2022/#accent-color Sure it's a "nice to have" but it bloats the spec? Look at the current actual implementation: https://web.dev/accent-color/#guaranteeing-contrast chrome and firefox already tint differently... How is this better than a good ol CSS variable and leaving it up to the designer to manage? Sure http://dowebsitesneedto…

Good joke, an exec testing in different browsers to ensure the color tint is the right color.

Re: State of CSS

#9
post #6

I think I don't need the 2022 version, but the 2021 version. Or even the 2012 version, lol! I still prefer to use tables to layout my websites. Question: Say I want a layout that has a top row, a middle row and a bottom row. Each row gets 33% of the screen space. Unless the content does not fit. Then the row should expand to the content. Here is the table version: https://jsfiddle.net/vg2ey8r9/ How do you do that wit…

Eg grid + vh unit. Look them up and you should find plenty content!

Re: State of CSS

#10
post #6

I think I don't need the 2022 version, but the 2021 version. Or even the 2012 version, lol! I still prefer to use tables to layout my websites. Question: Say I want a layout that has a top row, a middle row and a bottom row. Each row gets 33% of the screen space. Unless the content does not fit. Then the row should expand to the content. Here is the table version: https://jsfiddle.net/vg2ey8r9/ How do you do that wit…

CSS Grid.
Post reply on HN