4 ms·
I've never really understood people who say CSS is horribly designed. In some ways, we are trying to apply desktop application design paradigms to something tha
by yesimahuman 13y ago
I've never really understood people who say CSS is horribly designed. In some ways, we are trying to apply desktop application design paradigms to something that started document or content oriented.
I can tell you that I'd much rather use CSS than Android XML layouts, or WPF, or adding layout containers a la Swing or AWT. It's simple, easily understood across disciplines, and very powerful. Elements of a pretty well designed system.
- anonyfox 13y agoi second this. CSS may be crap, but switching from frontend-development to swing-stuff makes me wanna hang myself after a few minutes. (And i worked with awt/swing/swt long before i touched CSS.)
- lmm 13y agoTry qt/smoke if you can. An API that actually makes sense and just does what you expect - or you can use QML, which is what HTML for applications ought to look like.
- DougWebb 13y agoDocuments, in the real world, are full of layout that has been difficult to replicate in CSS. And to counter your point more directly CGI and the concept of web applications existed before CSS 1.0, so there was already need for application-style layouts when CSS was being designed. Flexbox isn't the answer either. I had high hopes for it and I'm in the middle of redesigning a web application UI using Flexbox for layout, and I still can't do some basic things like have an overflow:auto content area that expands to fill the space between a fixed left-hand nav panel, a variable-height fixed header, and a fixed footer. I'm still stuck with a bunch of javascript and a window.resize event handler to measure some heights and adjust the sizes of my containers. Maybe the upcoming CSS grids will work, but it'll be another couple of years before support is wide enough for me to use them. EDIT: I also wanted to say that I've learned xaml in the past few years, and that's absolutely not the direction I'd want CSS to go.
- orangecat 13y agoIt's simple, easily understood across disciplines, and very powerful. Elements of a pretty well designed system. On the other hand, it's 2013 and we're still trying to figure out how to center one element inside another. In some ways, we are trying to apply desktop application design paradigms to something that started document or content oriented. Which is exactly the problem. Web development today is a Turing tar pit, because we're using tools that were originally created for very different purposes. HTML is great for static documents, and lousy for apps. Javascript is great for attaching dynamic behavior to widgets, and lousy for large-scale software projects. CSS is great for consolidating style information, and lousy for layout. Yes, after over a decade of hacking by many smart people we've built up elaborate frameworks that sort of do what we want most of the time, but I wish we could have had more appropriate tools in the first place and been able to spend those resources elsewhere.
- peterhunt 13y agoAgreed entirely that this is the problem today. However we did have that (Java applets), and they didn't take off. I think the web did hit a bit of a sweet spot at the time, but it's time for us to build new technology on top of it. Personally, it's looking like asmjs, inline styles and translate3d divs to me :)
- hamburglar 13y ago> On the other hand, it's 2013 and we're still trying to figure out how to center one element inside another. 100% this. CSS is a very powerful tool if you know its quirks very well, and there are a lot of quirks. I know a lot of incredibly talented developers who can pick up any programming language or technology in no time at all, but still occasionally waste half a day circle-jerking with CSS trying to make it do something incredibly simple like center one box in another or baseline-align a couple of pieces of text.
- grandpoobah 13y agoWpf is fantastic, it is everything html could ever wish to be.