pistolero (p@fsebugoutzone.org)'s status on Thursday, 13-Feb-2025 13:25:49 JST
-
pistolero (p@fsebugoutzone.org)'s status on Thursday, 13-Feb-2025 13:25:49 JST pistolero
@shibao @hierarchon @a @sun
> it's literally just more concise inline styles
Using it that way is a bad idea. The idea is that you have a structure, and the CSS moves the decorations out of it: it's a separation of concerns. The HTML is data (and it is supposed to be machine-parseable), the CSS is presentation. So bad CSS class names describe how you want a thing to look, good ones describe what type of thing it is, and even better is if you don't even put classes in. (My only complaint with microdata annotations are that the schema.org URLs are ugly and massive, but if you combine properly structured HTML with the microdata, your CSS becomes things like "A person's image should be left of their bio" and "the cancel button should be faded slightly".)
Dipshit webdevs have almost come full-circle on this by shoving all the data into JSON and the presentation into CSS but then they generate the HTML with some massive JavaScript "application". If you take the JSON out and just use HTML, you're back to doing a thing that is fast, it can be made to look nice, and a machine that doesn't give a damn whether the corners are rounded or not doesn't have to examine the presentation logic, and HTML is better for describing most of this data than JSON is: you have links that describe relationships, you have a <form> that describes endpoints and <input> elements that describe the sort of things you need to give that endpoint (and can now provide client-side descriptions of valid data), things like that.
The "webapp" is a diseased thing, just a pile of JavaScript and some CSS that serves to approximate the PSD that the web dingus sent and a shitty pile of ads, but it could go back to being good.