Hacker News new | ask | show | jobs
by souplesse 1383 days ago
> Are you really suggesting that people should make Cascading Style Sheets do more than styling?

The parent made no such suggestion. You seem to be conflating the purpose of HTML classes with CSS. Here's a note from the "literal entire spec"[0], which other commenters have already pointed out:

> […] authors are encouraged to use values that describe the nature of the content, rather than values that describe the desired presentation of the content.

Furthermore, the parent took great pains not to attack Tailwind, instead pointing out that the two different approaches could easily coexist.

If you'd like to use class names solely as CSS hooks, go right ahead, but citing "correct attributes" is ironic at best.

[0]: https://html.spec.whatwg.org/multipage/dom.html#global-attri...

1 comments

There is no evidence that eg Google uses arbitrary class names in order to index metadata over the accepted standards of microdata.

https://developers.google.com/search/docs/advanced/structure...

I'm not Google but when I write a scraper I frequently use class selectors to pick out data. It's a rare occasion when all the information I need from a page is tagged as microdata.