News for hackers. Stuff that matters.
Re:Engineering for Slow Internet by arp242 on Friday May 31, 2024 @07:58PM (#40541513)
When used well, JS will improve the experience especially for high-latency low bandwidth users. Not doing full page refreshes for example, or not loading all data at once.

So no, "no JS at all" is not "by far the lightest weight" in many cases. This is just uncritically repeating dogma. Even 5K to 20K of JS can significantly increase performance.

Re:Engineering for Slow Internet by malinens on Sunday June 02, 2024 @03:33AM (#40552165)
I always ask people to give example of real world SPAs where JS is "used well" and nobody could give me an example
Re:Engineering for Slow Internet by arp242 on Wednesday June 05, 2024 @01:39AM (#40581699)
FastMail is pretty good; that's my go-to example.

However, you don't need to go full SPA. "No JS at all" and "SPA" are not the only options that exist. See my other comment: https://news.ycombinator.com/item?id=40541555

Sites like Hacker News, Stack Overflow, old.reddit.com, and many more greatly benefit from JS. I made GoatCounter tons faster with JS as well: rendering 8 charts on the server can be slow. It uses a "hybrid approach" where it renders only the first one on the server, sends the HTML, and then sends the rest later over a websocket. That gives the best of both: fast initial load without too much waiting, and most of the time you don't even notice the rest loads later.