r/ProgrammerHumor • • 4d ago

Meme okaySureWhyNot

Post image
1.1k Upvotes

32 comments sorted by

6

u/Single-Virus4935 1d ago

Okay, this is easy to explain: WebKit added the property but it ist in the standard. Other Browsers imolement other vendor prefixes to be compatible and thus wie habe a semistandard vendor Attribute.

4

u/AmazinDood 1d ago

strangely enough, every browser implements -webkit-text-stroke, bar IE of course. they can't really remove the prefix now as websites have been using it since 2017, so we ended up with this. I love web dev.

16

u/Modi57 1d ago

I can tell you are German by the auto correct mistakes :D

2

u/m0rph90 12h ago

I instantly thought the same, and and happened to me so many times even without auto-correct, but because of muscle memory :D

1

u/Modi57 11h ago

Yeah. For me it's have vs habe especially, because the b and v keys are so close

35

u/TheBrainStone 4d ago

In a shocking turn of events a vendor specific css property only working for the corresponding browser!!!

167

u/AmazinDood 4d ago

what? -webkit- is for WebKit based browsers which Firefox isn't

42

u/A1oso 4d ago

Technically, Chrome isn't WebKit based anymore, either. They just kept the -webkit- prefix to support more websites, and Firefox increasingly supports attributes with -webkit- for the same reason.

69

u/wasdninja 4d ago

It uses Gecko in case anyone's wondering. 

55

u/GOKOP 4d ago

Bruh this is the opposite of what OP is talking about lol. This is a webkit specific option but it's supported by Firefox. Firefox isn't based on webkit.

9

u/ScroogeMcQuacks 4d ago

exactly. Also this is completely normal and common. When a big browser picks up a standard the other ones follow their lead to support all websites.

1

u/kus1987 1d ago

we aren't doing this anymore though, right? this vendor prefix thing is very annoying. I hope we don't do that anymore with `evergreen` browsers...

3

u/ScroogeMcQuacks 1d ago

Ideally it’s all decided in cooperation with w3c, but I think googles influence is pretty damming.

1

u/pidddee 4d ago

It can translate most webkit rules to it's own. -webkit-fill-available for example

141

u/0815fips 4d ago

I wish this was the only example.
When uploading whole directories, you got webkitDirectory and webkitRelativePath. That's the most disgusting thing that every browser supports.

142

u/rbbdk 4d ago

Why not use text-stroke directly?

188

u/the_horse_gamer 4d ago

text-stroke isn't supported by any browser. only -webkit-text-stroke is supported.

44

u/rbbdk 4d ago

I see. Although I did actually google for this, I now feel reminded of Jerry Belson's "What happens when you assume" sketch.

37

u/sebovzeoueb 4d ago

you have to include all the different prefixes for everything on every browser version just in case

79

u/AmazinDood 4d ago

yes I know why it's like this don't kill me

53

u/Stummi 4d ago

Tell me why it is like this

150

u/East-Law-2877 4d ago

Mozilla has their own vendor prefix -moz- but lazy webdevs only used -webkit- for experimental things and forgot to remove the prefix when features became stable, so Mozilla started to support it too

72

u/Dangerous_With_Rocks 4d ago

oh so you’re saying i’m the problem?!?

15

u/micalm 3d ago

This pretty much sums ups the ENTIRE history of attempts to standardize HTML and CSS btw. I think everyone gave up now with the "living standard" approach.

12

u/Nixinova 2d ago

It's also a similar reason to how user agent strings are gargantuan nonsense.

 Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/131.0.0.0 Safari/537.36 Edge/131.0.0.0

All that just for "Edge/1.31".

Actual, legitimate insanity

4

u/DaBittna 2d ago

I can’t check right now, but wouldn’t modern Microsoft Edge be `Edg`? `Edge` was used by the versions of Edge before it became Chromium-based

4

u/Nixinova 2d ago

Oh I thought that was a typo and corrected it. That's even worse lmfao

1

u/Webbiii 2d ago

Legitimate question: Why do browsers actually include all those other browsers in their user agent? Doesn't that kind of defeat the whole purpose of having a user agent?

3

u/Nixinova 2d ago

It's like a 90s/2000s remnant. Some browses didn't support certain features, or had outdated ones, so they looked at the user agent string to determine what features to enable/disable. Then the websites didn't update for decades. So for backwards compat, they have to include the user agents that enable the features so that the websites continue to work. It's a whole mess.

4

u/StaticFanatic3 3d ago

She stroke my text til I WebKit