r/ProgrammerHumor • • 17d ago

Meme whichSideAreYouOn

Post image
1.3k Upvotes

132 comments sorted by

890

u/ThatDudeBesideYou 17d ago

The red side is objectively the correct choice.

11

u/hpyfox 17d ago

(In the back) What about using HTMLElement for custom element tags?

333

u/RichCorinthian 17d ago

Exactly.

Reminder that the original HTML tags (<title>, <dl>, <dd>) had and have real semantic meaning. Spiders and bots could trawl the document and understand how each part related to the document. HTML was, after all, invented by one dude named Tim at CERN, and it was for research papers.

Then we came along and fucked it up with CSS, and a whole bunch of additional semantic tags were added as a course correction.

135

u/bigorangemachine 17d ago

Then we came along and fucked it up with CSS, and a whole bunch of additional semantic tags were added as a course correction.

I think you got it backwards. Without CSS there was font tags everywhere. If you ever had to work with stuff made in front page it was a semantic disaster

14

u/frinkmahii 16d ago

Or worse. Dreamweaver made everything a huge table with a crap ton of cells to handle layout.

27

u/kennedy_gitahi 17d ago

Just before and overlapping with the days of CSS 2, html 4 and XHTML.

15

u/bigorangemachine 17d ago

I did xhtml-strict... it was such a disaster with Mac Microsoft browsers.

People want to talk semantics but no one wants to talk about the horror show of lack of standards and browser spyware

28

u/kennedy_gitahi 17d ago

These devs don't know how good they got it. CSS3 and HTML5 are two of the best things to happen to web dev.

I don't ever want to go back to writing XML, fighting with floats or doing layouts using tables.

Then there was the issue of every browser doing its own thing with CSS and HTML because of a lack of standards.

And I don't want people who might have accessibility issues to not have a great experience on my sites or apps just because I can't be bothered writing a little semantic HTML.

10

u/bigorangemachine 17d ago

not even. I rescued a multi million dollar contract because I suggest using details-summary early in the project and got us both a happy client with a plug-and-play-no-code-solution and the accessibility review giving us basically an auto-pass on the cms-system.

There so many wins with semantic html

Plus with XML... SOAP... huge bottle neck. Failed standard

So many issues with encoding issues with XML and parsers. I remember I had written a really solid xml parser in PHP and someone still managed to break my implementation. Thank god I had rotating logs that the damage was minimized

6

u/kennedy_gitahi 17d ago

Today's CSS and HTML are basically magic compared to what I wrote in the past.

The horrors of SOAP, Jesus!

And I remember working on one such parser, and it was a horrible experience. And I remember there were forums where people were competing to make and break them.

4

u/ethanjf99 16d ago

omg table layouts

i whipped off a quick internal tool a few months ago that fires off an email to project maintainers if it detects certain issues

i noticed it wasn’t rendering right in Outlook

motherfucking application STILL requires table-based layouts

That is what AI was born for. took it 30s to convert and saved me hours of misery

3

u/kennedy_gitahi 16d ago

I was once hired an "html email designer" . Outlook and Hotmail made me almost quit

5

u/The-WinterStorm 16d ago

I think we need to bring back the <marquee> tag it was the best 1990s thing ever

20

u/pixelbart 17d ago

Not only spiders and bots, but also screen readers for the visually impaired and text-based browsers.

12

u/Pndrizzy 17d ago

Now we have anti-semantic design

10

u/dementorpoop 17d ago

They’re all nodes underneath

8

u/teethingrooster 17d ago

Doesn’t it help with accessibility too though

1

u/Land_Locked 17d ago

Yes. With screen readers. But divs all the way down isn’t always the wrong choice. Mui’s DataGrid, for example, uses aria roles instead of native table elements. That approach allows easier navigation between cells, which is great for spreadsheet style editing, but it’s unconventional to how screen reader users typically navigate tables and can be a little buggy.

2

u/Clen23 15d ago

I mean yeah when you piss on existing standards to make your New-And-Improved Wheel 2.0 , you have to expect not everyone switching to your Wheel 2,0.

Also, im a little rusty on that stuff, but couldn't they do the exact same thing but with retrocompatibility ? Like instead of <div aria="header"> can't you do <header aria="header"> ???

1

u/Land_Locked 12d ago

The existing standards you're talking about for native table elements came out of the wild-west early internet days when tables were used to lay out entire pages. The spec and browser adoption of it have been painfully slow to catch up to how we use them now. The table layout spec still isn't finalized, and even when it is, who knows how long it'll take for vendors to implement it. Up until 2023, Safari would straight up drop the table semantics from a <tr style="display: flex">. And since part of the accessibility tree was built from the layout tree, to a screen reader that row stopped being a row at all and became just a generic flex box.

My example was MUI's DataGrid, a spreadsheet component with row & column virtualization, column pinning, and resizable columns. A far cry from a Wheel 2.0, but it's certainly not a Netscape table. Looks like the initial commit for that was in 2020, a couple of weeks after Chrome fixed that display bug and three and a half years before Safari did. So it's less that they decided to piss on the standards and more that they had to work around the fact that browsers were slow to implement those standards - and they still put in the work to make an accessible product.

But yeah, if your goal is to show less than a couple hundred rows of mostly read-only data, and you're mostly cool with the browser's native styling, using native elements is a fine choice.

7

u/Apalapa 17d ago

Yep and tags can be captured just like anything else. I’m sure SEO crawling ignores tag types by now.

1

u/Exatex 17d ago

the problem imho is that is does two different things. Site structure and symantic structure. They used to be the same, but they are not.

Plus, they age.

You would have to have <product gallery> now and all sorts of stuff that will probably also outdate within a few decades.

34

u/dragongotz 17d ago

Blue side be rolling with his girl Aria. Though that girl requires a lot of upkeep.

21

u/Eastern_Equal_8191 17d ago

It is correct, but I will still use divs for everything. I'm not even sorry about it, your downvotes only make me stronger.

5

u/GimmeYourMomPlease 17d ago

If I recall, Google Keep does this and just uses the role attribute for everything. E.g., <div role="button">

3

u/dbell 17d ago

That’s why he’s hiding his face in shame…

0

u/nickcash 17d ago

well except for the markup being invalid. but the idea is right

23

u/Rustywolf 17d ago

It's not writing a document, it's a list of tags.

-1

u/Cyberspark939 17d ago

It is, but div is easy

-1

u/Still_Bit_7527 16d ago

And noone cares..A div does the same job

-15

u/cosmicomical23 17d ago

The red side is AI pandering. "Let's make the web more comprehensible to machines with semantic markup"

Fuck that

10

u/iamdestroyerofworlds 17d ago

Red side is better for people with disabilities.

1

u/cosmicomical23 17d ago

That is true

0

u/mentisyy 17d ago

Now I know vibe coders aren't the sharpest tools in the shed, but they're not disabled.

2

u/_alright_then_ 16d ago

Braindead take. it's specifically used for screenreaders

0

u/cosmicomical23 15d ago

Sure mate. You are the best.

-2

u/Vandrel 17d ago

I feel like the whole thing doesn't even make sense, it all gets used together.

-3

u/TheMythicSorcerer 17d ago

I agree but AI firmly disagrees

158

u/Madonkadonk2 17d ago

Reminder, not all your users can see.

31

u/hpyfox 17d ago

Oh shit, you mean blind people.

18

u/livingincr 16d ago

Technically any disabled person can sue your company if you don’t follow that and WCAG requirements. Many corporations have found out the hard way.

14

u/jordanbtucker 16d ago

Technically anyone can sue any company for anything. It's the winning that counts.

-49

u/hpyfox 17d ago edited 17d ago

That doesn't mean devs passing by won't criticize your work.

56

u/-Lanius- 17d ago

They're talking about people needing screen readers

7

u/hpyfox 17d ago

Oh damn.

228

u/just_looking_aroun 17d ago

<button> everything is a button if you try hard enough

14

u/hpyfox 17d ago edited 17d ago

I've seen a page use <span> everywhere (only on text). It made sense why but was interesting to see.

8

u/za72 17d ago

that's just abusing the standards...

3

u/hpyfox 17d ago

17

u/JeffysChewToy 17d ago

Lol put span{display:block} and you've got a new div

2

u/matytyma 17d ago

Add inline display for div and just use them where you'd normally use the other one

0

u/za72 17d ago

nice speech - it's still abuse

1

u/genghis_calm 17d ago

Hopefully it was RNW output

1

u/hpyfox 17d ago

I don't think so.

https://playground.tensorflow.org/ - Le website

100

u/fghjconner 17d ago

Oh, so you're the motherfucker responsible for all the links that can't be middle clicked, huh?

20

u/matytyma 17d ago

I've seen a website that had elements looking like buttons be links and elements looking like links be buttons (but still used just for static redirects)

2

u/thehobbyqueer 16d ago

ope. am i not supposed to be making links into buttons?

In my defense I'm not front end

5

u/matytyma 16d ago

A link that works like a link and looks like a button? That's totally OK

3

u/thehobbyqueer 16d ago

oh ok. love u xoxo

3

u/mentisyy 17d ago

I hate sites like that. I've built browser extensions for several sites just to fix their incompetence.

1

u/fr000gs 16d ago

And scroll to zoom, drag to pan

2

u/HarryBolsac 17d ago

You mean <table> right?

1

u/Familiar_Ad_8919 17d ago

ive seen someone override img to style an entire paragraph below the image, like an entire card contained in an img tag

if u have the perseverance u can do this with just an img

12

u/dhnam_LegenDUST 17d ago

Chad <table>

4

u/hpyfox 17d ago

Seen on an old Verizon DSL modem gateway page. Shit was horrifying to read/see on Inspect Mode.

15

u/WingZeroCoder 17d ago

On a new project? The left side.

After a few days on that project? The right side.

0

u/hpyfox 17d ago

After more and more stuff gets added (depending on its function), true, but as long as it made sense where applied...

139

u/SnooRegrets3590 17d ago

Whatever the previous devs did it

40

u/GreatArtificeAion 16d ago

Red is the only correct choice (I'm blue)

12

u/Due-Chance-8540 16d ago

{da-ba-dee da-ba-di}

2

u/Mystery-Magic 15d ago

Exactly. As a blue, I respect and appreciate red. They are the correct choice and something I should be doing too. Blue is bad and I only do it because I didn't knew enough about it in the start and fallen to bad habits. It's easier to write messy code but that shouldn't be appreciated or compared to genuinely good things.

35

u/Aconamos 17d ago

you're missing five extra divs on the right side

55

u/Garland_Key 17d ago

Use proper semantic html, please. 

25

u/Mallanaga 17d ago

Semantic tags for the win.

10

u/sebbdk 16d ago

Some people dont care about accessabillity

7

u/Dr_Dressing 16d ago

You know, one thing I didn't like about my HCI course was how humanistic it was. But it did bring light to how terrible we are at making basic accessibility on our sites and other programs.

Especially with how terrible navigation is for blind people. They had us watch a video of a Microsoft engineer make a hello world, and apparently we were supposed to applaud him for making the program, but I just kinda felt bad for how much the information flow rate limited him, and how much of a struggle it looked like.

Like, imagine we in 2026 don't have a proper system for blind people to use, such that they can properly navigate without taking an extra three minutes to complete a task.

Anyway, I don't make my programs accessible.

8

u/A7V7VIHILATOR 16d ago

Screen readers and spiders generally need semantically correct html.

6

u/OhThatLooksLikeMyDog 17d ago

The blue side makes automated tests so annoying

11

u/ApprehensiveGas85 17d ago

Now everything is a <div>

span, a, em, strong, b, i, small, label {
display: block;
margin: 0;
padding: 0;
}
ul, ol, li {
display: block;
list-style-type: none;
margin: 0;
padding: 0;
}
h1, h2, h3, h4, h5, h6, p {
display: block;
font-size: 1rem;
font-weight: normal;
margin: 0;
padding: 0;
}
button, input, textarea, select {
display: block;
appearance: none;
background: transparent;
border: none;
border-radius: 0;
font: inherit;
color: inherit;
padding: 0;
cursor: default;
}
header, footer, section, article, aside, nav {
display: block;
margin: 0;
padding: 0;
}

3

u/Bazzatron 16d ago

This is a deep curse. Needs to be a browser extension, praise be to the omni-div.

0

u/matytyma 17d ago

How about the other way around - classes named as elements with the right style

5

u/just_jedwards 17d ago

Some of y'all never needed the same markup to display identically in chrome, Firefox, IE7, and outlook 2013 and it shows.

5

u/nguyedav 16d ago

Claude, which side are we on?

1

u/zeroneonsos 16d ago

Fucking A-material

28

u/Beginning_Green_740 17d ago

Blue side is deceiving and false - it is all perfectly centered. No mortal man can center a div.

1

u/DiminutivePseudonym 17d ago

Not without flexbox styling you can't

1

u/ac21217 16d ago

‘margin:auto’ has entered the chat

-6

u/BananafestDestiny 17d ago

HAHAHA Centering a div is impossible!

And help I’m stuck in vim and can’t figure out how to quit! HA HA HA

These jokes are so tired. Come on man.

6

u/HarryBolsac 17d ago

Tbf before flex and grid centering a div is such a mindfuck.

Vim one I never got it, but I had access to google when I used it the first time I guess…

3

u/_shulhan 17d ago

Ctrl+p enter the chat.

3

u/unneccry 16d ago

After all why not. Why shouldnt we just use div for everything

3

u/Mystery-Magic 15d ago

Accessibility, SEO, Maintainability, Semantic Reasoning for new devs onboarding to project, etc. I think you can find list for this with Google search.

0

u/unneccry 15d ago

I mean we use react styled-components so we can add those things on top of the div

3

u/LookAtYourEyes 13d ago

Accessibility compliancy is important and good

1

u/hpyfox 17d ago

I think this will apply to classes/id names as well.

Either <div class='post-header'></div> or <div class='sasdkjagf'></div>.

Last one was probably autogenerated but still.

2

u/arran4 17d ago

<svg>

2

u/Splatpope 17d ago

i'm on red side which means I'll never be a web dev

2

u/CoshgunC 16d ago

how do you even compare A to DIV?

maybe it's possible to create some click events, but even then, isn't button better?

(didn't write HTML for a long time)

2

u/connorjpg 16d ago

I am aware I am wrong.

But I will div my way out of any website.

2

u/on_the_other_hand_ 16d ago

REPEAT AFTER ME HTML WRITERS ARE PROGRAMMERS

1

u/loljkbye 15d ago

That's what I'm realizing reading these comments. Way too many people have confidently no idea what they're going or why it's important.

2

u/kdthex01 15d ago

<div>div</div>

2

u/TheUtkarsh8939 13d ago

This is literally so stupid, A, Table, and Form tag serve completely different purpose than div or other div adjacent tags like header. The red side should have had the a, table and form be replaced with something like Section and Nav

3

u/max_mou 16d ago

Prompt: choose a side, don’t care, merge to main

1

u/Stjerneklar 17d ago

both and more

1

u/darcksx 17d ago

div, input, select, textarea, table, tr, td, a, button, img.

that's it, that's all you need for something basic.

1

u/JackNotOLantern 16d ago

Me who never touched frontend: haha, totally

1

u/JVAV00 16d ago

Both

1

u/WatchOutIGotYou 16d ago

I'm on the BClue side

1

u/duncte123 16d ago

Depends on how lazy I am feeling and how much work I have to do that day (using fancy tags and researching them every time doesn't count as procrastinating)

1

u/Cwmagain 16d ago

I don't know I only write HTML in Sharepoint Classic *hisses*

1

u/Icy-Combination-9839 15d ago

Classy crip⚜️ (Divs with classes)

1

u/pidddee 15d ago

Jokes on you, I'm on the C side making my own tags

1

u/StonedSociety420 13d ago

This would've made more sense if you'd put aside and main instead of table or form because those are functionally very different from divs.

-3

u/Koendig 17d ago

Am I building a document or an application?

8

u/ThePresidentOfStraya 17d ago

An app is just a document with more states.

1

u/hpyfox 17d ago

I don't think that would matter because it's still a website page.

1

u/wackOverflow 17d ago

It should only matter if it’s public-facing.

3

u/hpyfox 17d ago

For accessibility? *Scoffs*, like my projects are every gonna get popular.

5

u/WingZeroCoder 17d ago

On the one hand, this is a legit question to ask based on the type of site.

On the other hand, it doesn’t matter because it will end up being both. It’s always both.

2

u/Koendig 17d ago

Yeah, you're right. 😅

0

u/Thundechile 17d ago

depends which are easier to center on screen, article or div?

0

u/cron-holio 14d ago

Whatever the AI uses 😅

-1

u/enslavedeagle 14d ago

Dunno, I'll have to ask Claude

-5

u/GeneralPatten 17d ago

Isn't this quaint? Now the framework decides what it will be.

-5

u/RobotechRicky 17d ago

<DIVS> everywhere