News for hackers. Stuff that matters.
Re:SPAs Were a Mistake by mattwad on Wednesday March 02, 2022 @12:41PM (#30530151)
I feel like most people that hate SPAs never have to deal with this type of thing, or even only have to work on the backend. They just don't get it. Of course, if you're using a SPA for a static website, you're also doing it wrong but that doesn't mean SPA itself is a bad thing.
Re:SPAs Were a Mistake by zippergz on Wednesday March 02, 2022 @01:06PM (#30530534)
I'm living proof that it is possible to simultaneously hate SPAs and understand why they are popular. I've built and worked on a number of them, I don't have a better alternative to recommend, and yet I still hate them because I think they are a clunky solution to the problem. We need something better, but I'm not smart enough to come up with what that should be.
Re:SPAs Were a Mistake by kitsunesoba on Wednesday March 02, 2022 @03:26PM (#30532611)
I don't think I'm any more smart when it comes to this particular issue, but my thought is that the answer probably has something to do with more primitives that are suited for web applications being provided by web browsers, so it's both easier to build a web app without some huge gangly framework and so frameworks have more to build on top of and less manual footwork introducing room for error.
Re:SPAs Were a Mistake by simonw on Wednesday March 02, 2022 @04:36PM (#30533522)
"They just don't get it"

Believe me, I get it.

I dealt with building these kinds of features for a full decade before SPAs became fashionable.

Now I'm stuck here watching in frustration as people go all-in on SPAs because they didn't know how to solve these problems without them.

Re:SPAs Were a Mistake by somishere on Wednesday March 02, 2022 @06:10PM (#30534727)
I've also been building these things for a number of decades now. That said, I thoroughly enjoy using the various, modern APIs and standards that have come together to enable single page apps. I'm all for first principles, but which stack are you talking about? The "backend" of the web has been about abstraction for a long time now. Building "these kind of features" has become easier and cheaper on any number of fronts.
Re:SPAs Were a Mistake by rosenjcb on Wednesday March 02, 2022 @01:38PM (#30531000)
I agree. These people hating on SPAs are mostly not frontend developers. They're backend devs that think returning an HTML page is all you need to do. Modern websites are very complex.
Re:SPAs Were a Mistake by WillPostForFood on Wednesday March 02, 2022 @02:00PM (#30531307)
Or users who hate watching a whole application load to display some text.
Re:SPAs Were a Mistake by rosenjcb on Wednesday March 02, 2022 @02:18PM (#30531570)
If the only purpose of your site is to load some text or an image, go use a framework with SSG like NextJS. Then you get fast websites without having to pretend that writing stateful updates (e.g. jQuery) to the DOM is fun.