Live data from Hacker News

Incomplete List of Mistakes in the Design of CSS

wiki.csswg.org

61–70 of 111 posts

Re: Incomplete List of Mistakes in the Design of CSS

#61

> Box-sizing should be border-box by default. Didn't older versions of IE do precisely that, leading to endless frustration? I hate to say it but MS did something right for once.

What frustration? The IE box model is the superior model. It's the way graphic designers naturally think about layout: You make a box then fill inward. Easy grid based layout. It's insane to figure out the size of your inner content and grow out—always subtracting from your desired total width.

Re: Incomplete List of Mistakes in the Design of CSS

#62
post #45

Earlier quoted context omitted.

Are you seriously trying to deny IE6 isn't there in the wild? It was a job I had to do. I was paid to do it. It was awful. This happened circa 2013. For contrast I now support IE8 and IE9. Without jQuery. It's bad. Really, really bad. Like, there isn't indexOf on Array and asking for polyfill is forbidden.

You're one-off job is nothing to be holding up as an example of current web development. My company has 23 active clients and I can't tell you the last time, many years ago, we saw IE8 in the visitors logs much less anything less than that.

I only was able to stop supporting IE7 this year :-P The only thing that has forced some of our customers to upgrade has been a year of successive SSL exploits that have rendered old browsers/OS insecure.

Re: Incomplete List of Mistakes in the Design of CSS

#64
it's not a css mistake, per se, but I always found difficult to reason about a way to tell "I don't really care how big this widget is, I care that this widget should be a rectangle with sizes of ratio X"; I want to be able to make a container, put a square on the top left, a 16/9 rectangle on the center and so on...

Re: Incomplete List of Mistakes in the Design of CSS

#65
If you ask me, a layout language should have simple orthogonal concepts in it. The reason CSS gets so much hate is, in my opinion, a lack of coherence, a lack of modularity and terrible naming choices.

You only have to look at vertical centering to see the problem. Situations that look almost the same require entirely different solutions, often causing a change to ripple through to parent/child/sibling elements.

Re: Incomplete List of Mistakes in the Design of CSS

#66

Earlier quoted context omitted.

In your latex equation, you are missing where the data goes. The idea for html/css/js is that data goes into the html, layout and styling into CDs and interactivity is defined in JavaScript. That makes sense. The problem is that we never got anything close to that.

The problem is it doesn't really make sense in 2015. Or rather, it only makes sense if you accept the technical debt inherited from HTML, which is itself the simplified stepchild of SGML, which was a 1960s idea and firmly rooted in paper publishing. Separating content and presentation isn't a bad idea. The badness happened because JavaScript - or some other web programming language - didn't appear until HTML was esta…

> So much layout and presentation is done with JavaScript anyway that it would make just as much sense to get rid of CSS and extend and standardise on something like jQuery-but-better to create an evolving cacheable layout library that bypasses browser quirks and uses exactly one common versioned codebase.

The concept of executing untrusted code is entirely antithetical to security. Javascript, or any Turing complete language, or perhaps that even is too precise a constraint, is a remarkably bad idea for setting the style of anything that is otherwise static. There's no good reason that text and images need be stylized via a proper language rather than static, non-executable statements.

> As a user, I keep finding sites that simply don't work in Chrome or Safari or IE or whatever.

I keep finding sites that simply don't work at all in Firefox with NoScript. Many of those sites are primarily just text and images which don't display otherwise. It's completely insane from a security point of view.

Re: Incomplete List of Mistakes in the Design of CSS

#67

another one not on the list is that any padding specified in % is always % of width. though this oddity/hack allows to responsively & proportionally scale images and backgrounds.

Honest question, what else could it be a %age of? Or should % not be an allowed unit of measurement of width?

Re: Incomplete List of Mistakes in the Design of CSS

#68

Earlier quoted context omitted.

The problem is it doesn't really make sense in 2015. Or rather, it only makes sense if you accept the technical debt inherited from HTML, which is itself the simplified stepchild of SGML, which was a 1960s idea and firmly rooted in paper publishing. Separating content and presentation isn't a bad idea. The badness happened because JavaScript - or some other web programming language - didn't appear until HTML was esta…

As a web dev of 11 years, I don't find writing cross browser code a nightmare. And any web site that doesn't work cross browser is by amateurs at best. I don't know what web sites you visit where you have such issues but I haven't seen them in years except for the occasional goofball site.

> And any web site that doesn't work cross browser is by amateurs at best.

Good luck arguing with customers that will only pay when you achieve pixel perfect layouts across all browsers.

Or are able to replicate certain UI behaviors from native platforms.

Doing native stuff again, and I don't miss this type of arguments.

Re: Incomplete List of Mistakes in the Design of CSS

#70
post #39

All that and nothing about variables?

I find myself often wishing conditionals on CSS until I remember that they aren't necessary because things like

    input[type="submit"]{}  
exist (but feel hacky as can be) and that if they did exist I would never, ever want to edit someone else's CSS file. Can you imagine the mess?

It would be nice not to have to look for a style:

1. inline html

2. in the CSS file(s)

3. in JavaScript (or js library)

4. in the source code in the backend

to find that one edit you need to make.

I think that limitation is the most frustrating, that because CSS cannot 'see' beyond its own little home it bleeds out into other documents.

Post reply on HN