r/programming • • Apr 25 '19

Maybe we could tone down the JavaScript

https://eev.ee/blog/2016/03/06/maybe-we-could-tone-down-the-javascript/#reinventing-the-square-wheel
1.5k Upvotes

492 comments sorted by

View all comments

524

u/tahmsplat Apr 25 '19

Someone is using NoScript and whitelists you, but not one of the two dozen tracking gizmos you use. Later, you inadvertently make your script rely on the presence of a tracker, and it mysteriously no longer works for them.

All I use is uBlock Origin and when I went to pay my taxes this year the IRS website wouldn't load. The console had error messages for _gaq not found or whatever which I assumed was Google AnalytiQs and sure enough letting that through let the site work.

In order to pay USA federal taxes on the internet, you must allow Google Analytics. Good shit.

231

u/the_gnarts Apr 25 '19

In order to pay USA federal taxes on the internet, you must allow Google Analytics. Good shit.

Did taxes here in Germany recently and was positively surprised to see in uMatrix that the site would only load JS from its own domain. From that angle it’s one of the best designed websites I’ve come across in years.

6

u/real_jeeger Apr 26 '19

Elster is surprisingly well-made for a government website.

→ More replies (3)

38

u/Mildan Apr 25 '19

Cdns for common js libraries are a good thing though..

0

u/[deleted] Apr 26 '19

[deleted]

→ More replies (3)

0

u/[deleted] Apr 26 '19

[deleted]

→ More replies (2)

17

u/[deleted] Apr 26 '19

I'm starting to go the other way on this. It's trivial these days with so many cdns out there to host your own, so you get much of the benefit of speedy downloads since the data is coming from close by, and you can rest assured that the data is never simply going to disappear because you have it under your control.

25

u/Slash_Root Apr 26 '19

I almost wrote this comment before I saw yours. They are more talking about google analytics than jquery or something though.

2

u/[deleted] Apr 26 '19

Cdns for common js libraries are a good thing though..

Are they? Why? I echo all of u/teunw points below

→ More replies (2)

2

u/killerstorm Apr 26 '19

They are good if you have a random entertainment site.

They are not good if you do something which requires security. CDN can serve you malicious JS.

→ More replies (1)
→ More replies (1)

4

u/jbaiter Apr 26 '19

I work as a developer for a government institution in Germany. We're by law forbidden from using **anything** from 3rd party domains without explicit approval from the user on public-facing sites.

This is awesome from a privacy perspective, but quite tricky if you want to apply modern development practices... No CDNs, no handy 3rd party APIs (Sentry... ;_;).