Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I think he's implying that traditional MPAs are relatively well-understood. The team will pretty much know how to make them and will not expect to break new ground on architecture, discover new things the model enables, or spend a lot of time on "How do we build applications?" versus just delivering on business goals. SPA development is less mature, so there's a lot more room (and sometimes need, or just temptation) to reinvent things.


Maybe I’m just full of Ruby on Rails induced trauma, but I can’t remember any particular pleasant memories. Every app would start with a reasonable and straightforward view layer, usually ERB templates sprinkled with jQuery, and then slowly but surely be consumed by one-off JavaScript snippets.

“We need a sortable table on this route and it should support pagination without a reload, but the pagination needs to be persisted to the address bar for outside link sharing.” This feature alone can introduce all kinds of unmanaged state and be a testing nightmare. And if another part of the site uses the same functionality, you’ve just signed up for an lifetime of maintenance, usually somewhere between your server-side templates, and your asset pipeline. God help you if your bugs can be described as, “I have some local state here, but I’m not sure how to get it either up or down to the right place.”

Personally, these kind of code smells demoralize me enough to consider a job elsewhere, preferably at a company that uses something like React where there’s bound to be complexity, but at least there’s component boundaries to keep your mental facilities from being overrun by a “simple multi page architecture.”


> “We need a sortable table on this route and it should support pagination without a reload, but the pagination needs to be persisted to the address bar for outside link sharing.”

How would you do that differently in a SPA? Or would that just preclude the link sharing, removing the requirement altogether?

Are SPAs doing client-side pagination or something?


I've seen a variety of solutions used in SPAs, from a thin wrapper around server-side pagination to some extremely fancy client mirroring of server state where the client builds an increasingly larger cache of the data coming from the server, complete with eviction strategies and maximum memory usage limitations, and only has to send a request to server side when it knows it cannot satisfy the client's viewing desires with what it's gathered so far.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: