7 ms·
Saying JS broke the web when your website loads 754kB of JS across 13 separate requests makes me wonder if you're very serious about the problem.
by onion2k 1y ago
Saying JS broke the web when your website loads 754kB of JS across 13 separate requests makes me wonder if you're very serious about the problem.
- rizky05 1y ago[dead]
- kachapopopow 1y agoWell, it's just wordpress and captcha can only be done in js (half the requests).
- onion2k 1y agoThis is the 'no true Scotsman' argument. "Websites that use JS are terrible and broken." "Your website uses a ton of JS." "JS is fine in my case. It's all those other websites that are broken!" You can implement a captcha without JS. You don't need jQuery or jQuery-migrate in 2025. The site is using Quill for some typography tweaks that could mostly be done in CSS. FWIW I don't think there's anything wrong with the way the site is built. It looks nice. It loads pretty fast. JS is great - it enables a bunch of capabilities for things that you can't do on a web page without it, and if you're looking for something very specific or hugely interactive it's essential. But I can make that argument because I'm not saying JS is bad. If you say JS is bad and you use it anyway for things you don't really need you're undermining your own point quite a lot.
- dudeinjapan 1y agoNo true Scotsman would ever use Javascript… I guess I need to buy a kilt!
- kachapopopow 1y agoI think you're stuck with jquery because of the theme engine and the comment section.
- josephg 1y agoWhy does a blog post need a captcha?
- serial_dev 1y agoI think it's loaded by the comment section.
- deleted 1y ago[deleted]
- zaphirplane 1y agoAbsolutely, do as I say not as I do.
- kachapopopow 1y agoThey do complain about wordpress using js... And the javascript files are rather tiny other than jQuery and recaptcha which is loaded by the comment section. I do want HCL so we can sunset helm since it really is not the tool for the job (and slow).
- norman784 1y agoYou are being generous, most sites ships at least few MB of JS garbage.
- mschuster91 1y agoOn a wired connection? No problem. On a crowded mobile network? Or when you got only EDGE (hello Germany)? Whoops. Hacker News however? Blazing fast - one page and only the CSS is actually required for rendering the page, and it is using both a cache-buster in the URL and a 10 year (!) cache life time. The JS uses the same as well but it's only loaded at the end of the page, so after rendering is done.
- gf000 1y ago> Hacker News however? While being completely useless on mobile, with tiny buttons and textarea, which could be fixed while barely making the whole thing larger.
- ale42 1y agoThat's not a JS problem. It's a UI problem and you mostly solve it with CSS and adapting the HTML, you don't need to add a 3 MB JS framework for that.
- ffsm8 1y agoMaybe we can do the fotm and instead generate it on the fly via an LLM? Each user can get their own stylesheet and every request will be a small surprise how it looks. Fantastic idea, right? No? Always these haters...
- vachina 1y agoHacker news is perfect on mobile. How often do you vote? It is so content dense it’s perfect for mobile.
- queenkjuul 1y agoThe reply, parent, context, and collapse buttons are almost unusably small
- gf000 1y agoHave you tried Sync, the reddit client? It's basically the same kind of content and it's night and day how much more usable and readable it is. Meanwhile I have to use a Firefox extension to make HN black-on-orange. But credit to lobster.rs, they also did an excellent job with the UI on web tech, while still being very reasonable on the css/JS side (though I can't check right now how much they serve)
- Springtime 1y agoTheir site loads fine without JS or cookies/local storage enabled though, which is more than can be said of many sites (and tbh what I was expecting the article to be about given the dramatic headline).
- serial_dev 1y ago> This isn’t about going back to table layouts or banning JavaScript. It’s about building with intent. > It’s not about purity. It’s about outcomes. > Use what works. I think the website is fast and the majority of that JS is for the comment section+recaptcha (that's also for comments?), website works without it, I can tab through things, and the site is accessible, so I don't think that hundred KB of JS is a big "gotcha!". However, considering barely any comments, I'd honestly just consider removing them, not because I' mind the couple of hundred KBs, but because nobody uses these anymore. All discussion happens on social platforms and forums.
- cyanydeez 1y agoSomeone should write a meta forum that just overlays related posts.
- Mo3 1y agoSo how did JavaScript break the web then? It didn't. Badly engineered sites suck. Nothing new.
- const_cast 1y agoNo this is partially Javascript's problem. JS has virtually no standard library and was, for a long time, a bad, lobotomized language. ES6 helps a lot, but in the meantime we had to rely on absolutely huge frameworks. JS also did not properly address the complexity of the web. We didn't have good APIs for manipulating the DOM. We didn't have good APIs for making server requests. We did things like spawn iframes to call XML endpoints that we then transform the result of into HTML via XSLT and then inject that into the DOM. And, on top of all of this, JS is not performant. It's an extremely footgunny language, too. So we build on top more complexity. Minimizers, linters, static analyzers, compression, obfuscators, and more. These days JS is no longer a scripting language - it has more build steps than a C++ project. So anyway, now here we are.
- jazzypants 1y agoSolid or Preact are less than 10kb, and captcha is pretty much useless at this point in my experience. There's no reason for this site to have over 70kb of JS. My blog has a similar comment section with less 15kb of JS. The funny thing is that almost half of the 70kb is jQuery which is basically baked into the browser at this point. However, I think that it's important to keep in mind that a "Hello World" app in NextJS is around 70kb as well, so I think that anything less than 100kb is pretty forgivable on the modern web. That's a rarer achievement than one would like to believe. To fully clarify my belief, I use a ~$50 budget phone, and it's rarely the JS that makes the web unusable. It's usually when a website loads multiple advertisements that each contain video tags that I actually notice a degradation in experience.
- Zealotux 1y agoI find your argument disingenuous, the website is still usable with JS disabled and it's obvious the article is talking about JS-heavy websites that could do without it, not advocating for a complete anti-JS stance. It also uses HTTP3 is seems, so making 13 separate requests isn't much of an issue, it has a good performance score which is almost surprising for a Wordpress website.
- nchmy 1y agoWhy is good performance surprising for WordPress? It's just html, and I assume it is fully cached since it's not a site that has login, dynamic stuff (that's when WordPress becomes a big problem, but can be surmounted).
- 1vuio0pswjnm7 1y ago"Saying JS broke the web when your website loads 754kB of JS across 13 separate requests makes me wonder if you're very serious about the problem." Truthfully, _the website_ does not load anything. The so-called "modern" web browser used by many but not all HN commenters auto-loads resources, e.g., processing <script ... src=... > tags, and runs Javascript, e.g., XHR or fetch requests. As such, by using a different client, not the one used by these HN commenters, this web page can be retrieved with only one HTTP request (initiated by the user) and and read, text-only, with zero Javascript files sourced. There are of course other strategies to avoid auto-loading resources and running Javascript. IMO, anyone who is "very serious about the problem" would surely be using one of them, and probably unperturbed by yet another blog page that tries to source some standard WorddPress Javascripts. Nor did Javascript "break the web". Web developers and web marketers did, using Javascript and browsers distributed by advertising companies, and organisations paid by advertising companies to send them data about browser users.
- nchmy 1y agoThe difference is whether js is in the critical render path. With ssr html, it doesn't need to be. It's just a sprinkling on top.
- deleted 1y ago[deleted]