Live data from Hacker News

You suck at CSS and that's okay (2022)

rexriepe.com

21–30 of 70 posts

Re: You suck at CSS and that's okay (2022)

#21
My view is that those who designed CSS suck when it comes to designing intuitive systems.

I would not advocate constraint solvers, in the future I hope ViTs are so cheap to run that they can infer the right layout of things at any orientation and size in single digit milliseconds, solving the layout problem for good =)

Re: You suck at CSS and that's okay (2022)

#23
And the fix is another framework, because of course it's another framework. Frameworks are to CSS what greige paint is to a house. Trying to implement the missing 5% of a CSS framework without knowing how to implement "complex" CSS from the ground up means you are never implementing the missing 5%. Your site or app or whatever is just going to look like every other site that uses that framework.

Now that CSS is more or less feature complete and the fact that there's just one web browser means you don't need the clever tricks rolled up in a framework to center a div or to have a grid layout that works without resorting to tables. It's literally part of the CSS spec and has been implemented in every browser for a decade now.

Re: You suck at CSS and that's okay (2022)

#24
post #22

The CASS site on iOS WebKit has bullets overflowing into the border and a mix of fonts that doesn’t look great: https://casscss.github.io/cass/

Thanks! Lists were the bane of my existence with this project. I could never make all the browsers happy.

This is a #wontfix (sorry), but I might fork it into a new, LLM-oriented CSS project. Fonts and lists will be the first things I look at.

Re: You suck at CSS and that's okay (2022)

#25

Tell that to a decent number of people I have worked with over the past 20 years. In fact, I know people to this day who have been writing CSS for decades who don't really know fundamental things like specificity, inheritance, or the cascade. Pattern matching into the sunset, not a single fundamental piece of CSS specifications ever internalized, still getting paid (its okay). https://www.w3.org/Style/CSS/specs.en.ht…

One reason I think Tailwind became so popular is that it makes it much easier to pattern match CSS. I don't think it's a good or bad thing, it's just a thing.

Re: You suck at CSS and that's okay (2022)

#26
post #15

The worst part of CSS is trying to come up with the class names. .every-stupid-ass__naming-scheme-falls-short{}

Why? Just ask an LLM if your taxonomy skills are weak. They'll transfer eventually.

Things like BEM give you the most flexibility for extension, things like atomic CSS (tailwind) give you the most velocity for not giving a fuck about ever touching the markup again.

Re: You suck at CSS and that's okay (2022)

#27
HN Confessional: I wrote a custom theme for my server management software a few years ago that's basically just a rewrite of the stock theme's rather large CSS file. Among a little more than 1200 lines, I include `!important` 175 times. I imagine that causes hives among our more discerning front-end devs.

Re: You suck at CSS and that's okay (2022)

#28

HN Confessional: I wrote a custom theme for my server management software a few years ago that's basically just a rewrite of the stock theme's rather large CSS file. Among a little more than 1200 lines, I include `!important` 175 times . I imagine that causes hives among our more discerning front-end devs.

It looks great, specifically for me. I can't comment on anyone else, but I have to imagine it's dysfunctional. I abstracted as many color and style options as possible to allow for a lot of variable-setting. I unreservedly apologize for the affront to common decency (but I'm probably still gonna use it). Gotta have that transparent glass effect on ma' netstats.

Re: You suck at CSS and that's okay (2022)

#29
post #3

> The last big driver of time-wasting in CSS is the drive for pixel perfection I agree. Also users/product managers do not care. They will see UI that is a little bit “off” and think negatively about your brand. Congrats, now you have a ticket to make the UI look pixel perfect. I suppose the audience for this isn’t people who actually get paid to write CSS, but instead casual blog writers. It’s definitely ok and norm…

Not even pixel perfection but also coming up with UX ideas by people who don’t understand technical details.

Like QA not passing some detail because they think it should be different. Where in reality it is what it is because of framework etc.

Yes you mostly can do everything - but not everything is worth spending time/money on.

Re: You suck at CSS and that's okay (2022)

#30
post #6

I detest writing CSS and HTML. I just find it boring fiddly and annoying. I have started doing "vibe" coding with LLM's. Giving a decent prompt produces results that are... pretty good. Almost 100% in lighthouse for both mobile and desktop, responsive, reusable components, dark/light mode and a design that was better than I could do in the 2-3 hours I spent doing it (while sipping wine). I know its not a solution for…

LLMs are great for building frontends for backend projects and backends for frontend projects
Post reply on HN