DEV Community

Discussion on: What are some pros and cons of Single Page vs Backend Heavy apps?

Collapse
 
niorad profile image
Antonio Radovcic

Some thoughts I have about this topic:

The server has the advantage of being under your control. The more computation you move to the client, the less certain the environment your software runs on becomes.

You can go pretty far with server-side-rendering in terms of snappy and performant sites. If you build a shop and want instant cart-updates and the like, you can use approaches like turbolinks/PJAX/Phoenix Live-View.

If you have a "normal" site, but there is one page with real-time-updates and state-heavy things, you can insert React/Vue/… into that page only. No need to go full SPA.

If you're building actual apps, like photo-editors; jira-like-tools; games; audio/video-platforms; e-mail-clients; chat-tools; analytics-tools etc., then I wouldn't think twice and pick whatever SPA-framework you and your team are most comfortable with.

If you have all of those concentrated in one huge app and multiple teams, you could make multiple front-ends, and switch between them via subdomains (vulg. "micro-frontends", DAZN does it this way)

Collapse
 
prahladyeri profile image
Prahlad Yeri • Edited

Thanks, appreciate your views! The client-side environment is a very dynamic thing right now. Its true that the client-side is fragmented but there has been an extreme push for standardization (ES6, et al.) and upgrades of browsers even on low-end android browsers.

On the server side, the most important determinant is perhaps cost which seems to be going against the Moore's law right now! Since the last decade or so, the prices of storage, memory and processors seem to be going up rather than down (or at least not going down in proportion to the Moore's law). If this trend continues, server-side processing will become even more costlier and SPA will rule the future (let the client browsers handle the costly memory and processing stuff!).

Right now, server side processing on AWS/Digital Ocean is seemingly affordable but when it comes to scaling, only the large MNCs like Google, Facebook, Twitter, etc. can do that, not the plebeians like us. The only way for us to scale is to move as much logic to client side as possible. My understanding is that even DEV.to is primarily a client side app?