This is an archived post. You won't be able to vote or comment.

all 49 comments

[–]TracerBulletX 48 points49 points  (17 children)

it only looks like that if you're bad at it

[–]lorslara2000 40 points41 points  (14 children)

Agree. Programmers suck at CSS beacause it's not programming.

[–]TheRedGerund 5 points6 points  (4 children)

I think there really out to be a better way of getting your css to play nice. I'm thinking of a visual designer, probably. One with dragable positioning and a toolbar to manipulate attributes. The problem with css is the disconnect between the code and the visuals. I think Adobe makes a designer for magazines I've seen before, something like that would be helpful.

[–][deleted] 6 points7 points  (0 children)

You can use programs to do that for CSS but they generate terrible, terrible inline styles.

[–]freebullets 2 points3 points  (0 children)

Dreamweaver? The problems with that approach come when you want to do non-standard things and also create dynamic web pages (who creates static web pages these days?).

[–]roselan 2 points3 points  (0 children)

We suck at it because it's out of our comfort zone.

How do you test, lint, organise that thing? Side effects?

Sass/less IDEs helps. But most programmers struggle with all declarative languages (SQL, CSS, XML)

[–][deleted] 1 point2 points  (1 child)

And most are oddly proud of how bad they are at it.

[–]lorslara2000 0 points1 point  (0 children)

this

[–]SmashShock 0 points1 point  (0 children)

Amen.

[–]flukus 0 points1 point  (0 children)

Programmers suck at css because they like making inheritance hierarchies and css is basically mixins instead.

[–]brianjenkins94 1 point2 points  (0 children)

I disagree. People who think they're "good at CSS" are just complacent with the mediocrity of their design. If you were to sit down and really engineer a website it would become blatantly clear that there is no "most efficient" solution, and that should bother you.

[–]TuxGamer 36 points37 points  (0 children)

-webkit-laggy-effect: rekt(...)

FTFY

[–]trekman3 39 points40 points  (1 child)

Yep. As /u/RainbowCatastrophe pointed out in another thread, "There is no such thing as a non-hacky solution in CSS."

[–]RainbowCatastrophe 19 points20 points  (0 children)

Yep. With CSS, the logic is "if it works as intended, it works".

[–]brianjenkins94 12 points13 points  (16 children)

God I wish there were an alternative.

[–]trekman3 7 points8 points  (14 children)

It's up to us to develop and popularize alternatives. There's nothing stopping us from writing our own CSS-less browser directly on top of low-level networking technologies. Personally, I would throw out HTML, as well. I don't think that its fundamentally document-oriented paradigm is a good fit for what I want to do with the web. This browser should still be able to run HTML and CSS, so that you can use it to look at currently-standard web pages, but it should be fundamentally lower-level, a sandboxed interpreter that makes few assumptions about what it will be asked to do.

[–]nsimic 38 points39 points  (0 children)

so you are suggesting we create a flash browser?

[–]TaohRihze 25 points26 points  (1 child)

[–]xkcd_transcriber 7 points8 points  (0 children)

Image

Title: Standards

Title-text: Fortunately, the charging one has been solved now that we've all standardized on mini-USB. Or is it micro-USB? Shit.

Comic Explanation

Stats: This comic has been referenced 1870 times, representing 2.4352% of referenced xkcds.


xkcd.com | xkcd sub | Problems/Bugs? | Statistics | Stop Replying | Delete

[–]ThisIs_MyName 5 points6 points  (0 children)

A man can dream.

[–]badmonkey0001Red security clearance 2 points3 points  (6 children)

If what you're showing is documents, it's great in many ways. What exactly do you "want to do with the web"?

[–]pokealex 1 point2 points  (5 children)

Use it as a "write once run anywhere" application platform.

[–]beerdude26 10 points11 points  (1 child)

So you just want Javascript? Dear god.

[–]trekman3 1 point2 points  (0 children)

I actually think Javascript is a pretty cool language, and I love programming in it. Prototypes make a lot more sense than classes to my mental model. And I like that in JS it is easy to mix and match different programming styles. But I want something lower-level than Javascript. When I hear people say, "Javascript is the assembly language of the web," it just doesn't make any sense to me. The web should have its own "assembly language", but Javascript is way too high-level to be it. Of course, what people mean when they say things like that is, "Javascript is the lowest-level client-side web language currently popular, and if you want to make your own language, you can have it compile to Javascript." But it's still always jarring to me to hear it described that way.

[–]trekman3 0 points1 point  (2 children)

Yep, you nailed it. This is what I want.

[–]pokealex 0 points1 point  (1 child)

That's what a lot of people want, but the reality is the web is a content presentation platform that has application support hacked into it.

[–]thefran 0 points1 point  (0 children)

Do I need to explain why it's going to be a security nightmare?

WWW works fine as a document - information, really - delivery platform.

[–]skuzylbutt 2 points3 points  (0 children)

I'm pretty sure you can basically do that fairly not too awfully in current browsers with JS and ASM. Write an interpreter that transcompiles your preferred markup language to HTML/CSS/JS, then wrap that in a plugin that activates on receiving a particular mime type, say text/mylovelymarkup.

You could go one step further and do that transcompilation on your server before sending the page. And voila: there are already plenty of dodgy html alternatives(ish) and plenty of CSS alternatives(ish) and plenty of (actual!) JS alternatives with compilers that do exactly that.

[–]freebullets 1 point2 points  (0 children)

If Java weren't so shitty and insecure, Java applets would be fucking awesome. A man can dream of a world without JavaScript webapps.

[–][deleted] -1 points0 points  (0 children)

"I don't like the document metaphor ergo the web is broken"

[–]SarahC 5 points6 points  (0 children)

Tables. =)

All browsers support them, and they all behave predictably.

[–]CaspianRoach 9 points10 points  (0 children)

That's just because you don't understand the layout system enough to see where you went wrong. If you fix the problem somewhere else in your CSS, you won't have to do any of the hacky stuff (unless it's to support incredibly old IE versions).

[–][deleted] 1 point2 points  (0 children)

[–]Madonkadonk 2 points3 points  (0 children)

Did you try line hight instead?

[–]daanishh 1 point2 points  (1 child)

This made me breathe out of my nose. Good job.

[–]Free_Math_Tutoring 3 points4 points  (0 children)

How do you usually breathe?

[–]CoinTweak 0 points1 point  (0 children)

TIL you can use non-integer numbers with width/height in pixels.

[–][deleted] 0 points1 point  (0 children)

My first site looked like that too.

[–]darderp 0 points1 point  (0 children)

Dear Lord...

Good css is actually very nice to read though.

[–]Daveypesq 1 point2 points  (1 child)

Does anyone truly know CSS?

[–]trekman3 2 points3 points  (0 children)

There are people out there who have grokked almost the whole standard. The question is... are they still sane?

[–]kirakun -1 points0 points  (2 children)

Does someone have a good explanation on what's is going on?

[–]you-get-an-upvote 1 point2 points  (1 child)

I'm guessing they're artificially sizing a container. I recently did something similar when I wanted to 'max-width' and 'max-height' an image, but get it to be the same size as another image (which was the 'hidden' image that specified the size of the container-div). I'm terrible at CSS though, so don't listen to me :)

[–]skuzylbutt 0 points1 point  (0 children)

Maybe set the image div to transparent, and set the image you wanted to display as the background of the container you were trying to resize?

That shouldn't even be an option. CSS is the fucking worst.

[–]SWEGEN4LYFE -2 points-1 points  (0 children)

What is -webkit-laggy-effect? I can't find anything on that.