4 ms·
Great article. In the 'real world' of my own little bubble, The average SPA is worse than the average MPA seems to come up pretty regularly, particularly in th
by iamben 4y ago
Great article.
In the 'real world' of my own little bubble, The average SPA is worse than the average MPA seems to come up pretty regularly, particularly in the ecom world.
I'm seeing more new sites being built as single page apps without any real need for them to be. Having been agency side in the past, it feels like either the businesses needing a new website are being sold some slick pitch about how SPAs are the future, or the devs have decided to reinvent the wheel because making MPAs is boring. Both are usually to the detriment of the end product.
When the new SPA site materialises there are SO many problems. Each one takes monumental effort to fix, because of stupid intricacies. External services stop working with it. Remember that thing the marketing team had been using for the last year? That no longer works; cue 3 months of reporting gaps. And that other thing you had in your tag manager? That now loads with every refresh (or not for any subsequent page!), and the JavaScript breaks after the first load. The data layer? See ya! SEO? See ya! Those Adwords gclids? "Oh we stripped those..." Etc. Etc. Etc.
I think a lot of the problem comes from developers not being in the weeds with the end product. 25 years of 'normal' sites and even the bits you don't know personally work pretty well. Stuff is solved. If you're the dev tasked with creating a new ecom site, if you've never had to put heatmaps in GTM, or enhanced ecommerce in the data layer for a checkout plugin - or whatever else - how do you know to build it in your SPA? And it's never going to be specced, because most end users just expect stuff 'works'.
I've used some brilliant SPAs. But jeez - do it well or don't do it at all. And 'well' shouldn't be judged by the developer.
- night-rider 4y agoYeah does every site need Gmail levels of complexity when simple HTML and a sprinkling of CSS will do the trick instead? There are people who disable JS for accessibility reasons and are locked out of reading certain text just because it requires JS. Then there’s the remarkable low effort of what’s put into the <noscript> tag. No description apart from the familiar: ‘This page requires Javascript’
- corrral 4y agoGmail doesn't even need gmail levels of complexity. The "basic HTML" version is already pretty good, and some very light extra javascript could easily cover what few gaps it has, no need for an SPA.
- lenkite 4y agoThe biggest crime - and I blame Google for this - is making basic web-components, even a Hello World mandatorily need Javascript. There was no need for mixing up web components with JS, except it didn't fit Google's agenda. Custom tags using HTML+CSS with no JS would have been utterly amazing for web fundamental development.
- tnzk 4y agoGenuine question from somewhat newbie in web components but afaik is JS required just for mounting a custom element, let alone its inside?
- ehutch79 4y agoWhy would I let the marketing team have any say in the site I'm working on? It would be completely inappropriate. If any of the sites pages appeared in any search engine I'd probably be fired, possibly be talking with lawyers.... ------- My point here is that not all sites are the same. SPAs don't work for content sites like blogs or a restaurants home page, or whatever. But for internal line of business stuff, they can work well. That's not to say a shitty site isn't a shitty site. It's not ok for any app to take minutes to load
- iamben 4y agoI mean - if your website is selling a million widgets a year, the marketing team are going to pretty involved (especially if you want to keep selling a million widgets a year)... So getting them involved in the spec is probably pretty prudent. And you're right. SPAs don't work for everything, which is exactly the point I was making. I keep seeing websites that don't need to be SPAs and have been built badly. But for the right project they can be great.
- ehutch79 4y agoRight. We agree then, there arn't a lot of content sites that would benefit from being an SPA. it'd have to be a multimedia extravaganza really. And since most of the web is mundane content sites, SPAs should be rareish on the public facing internet My point was that a lot of people seem to think everything sending anything over http is the same as the project they're working on. The demographics for every site being the same. the needs and requirements being identical.
- iamben 4y agoWell yeah. But at no point did I infer that everything over http was the same as the projects I'm working on. I literally started the comment with: "In the 'real world' of my own little bubble, The average SPA is worse than the average MPA seems to come up pretty regularly, particularly in the ecom world." And you're right, we absolutely agree that SPAs aren't needed the majority of the time.