3 ms·
TBH most of the cons stated in this article are just because of bad programming, not because it's a SPA > broken “back” button (sometimes it works properly, bu
by JohnnyCrazy 9y ago
TBH most of the cons stated in this article are just because of bad programming, not because it's a SPA
> broken “back” button (sometimes it works properly, but in general people don’t trust it)
If your UX is good, the user will notice data is refreshed when going back. All current top tier SPA Frameworks have support for correct HTML5 routing.
> broken “open in a new tab” behaviour – people like to handle links in onClick handler, and browser can’t recognize it as a link (even if the majority of the links are valid, sooner or later you’ll encounter a non-link “link”)
Again, most up-to-date frameworks have a fallback by adding a normal href so you can still CTRL-Click it.
> sometimes broken “refresh” button – after refreshing you end up in a different UI (usually slightly, but still different)
I don't see a real disadvantage here, since you can simply store your state by manipulating the URL or even localstorage. So you even have the possibility to not store your state...But again, application design, not SPA
I do agree with TTI (at least on the first load) and bad performance on low end devices.
- jordache 9y agoNo. Because it is an SPA, it means there is more work to restore the default behavior of the back button. That's the way he should have articulated his point. You also mention HTML5 routing.. Ok now you have to configure your web server to properly parse the URL and understand what it's conveying.
- thehardsphere 9y ago> TBH most of the cons stated in this article are just because of bad programming, not because it's a SPA The worst programming is the result of choosing the wrong tools for the job. There is a class of jobs for which an SPA is entirely unnecessary.