• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

Dion Almaer

Software, Development, Products

  • @dalmaer
  • LinkedIn
  • Medium
  • RSS
  • Show Search
Hide Search

Archives for May 2015

Is it time to go SPA only?

May 12, 2015 Leave a Comment


Four and a half years ago we set about building a conditional tier rendering engine. The timing was perfect. Node was giving us a viable JavaScript on the server solution (no offense meant to Jaxer and friends) so we could explore the dream of shared code on the client and server.

One of the other key reasons for conditional rendering was: appease the SEO gods! If your web application doesn’t have the need (or business model) for Google and friends to draw customers to your experience then you could go ahead and SPA away. For many, that wasn’t the case, and the Google bot and its friends wanted you to give them some nice clean markup.

The Google bot has continued to evolve, and we have been told that it has gotten better at speaking JavaScript itself. This article on a test to see how well this works in practice is a good reminder to run some tests yourself, and to rethink the role of server rendering.

Is it possible to go full on SPA now? Let’s take a look at what has changed over the years, take some guesses to the future, and see how that could lead us.

Performance

Sending down a fully rendered page on first load is what we are really talking about here. You could argue that it is viable to do full page reloads, but you may as well at least pjax right? Once the app is loaded, why bother tearing down and setting up on interactions?

Loadin, loadin, loading

We have all witnessed the “slow SPA effect” though. You know the one. After tapping a link the page goes from white to show some app UI, but then you are watching a custom spinner as it goes back to the server to get the real data. Irritating.

SPA doesn’t have to be this way though. Google+ was one of the first web apps that I saw that would send the data required along with the app for first load, and we can do the same on our SPAs. This way, the app is able to render itself right away vs. having to phone home an extra time.

Is this as fast as sending down the right HTML (and then co-opting it and taking over)? No. Is it the bottle neck to your performance? I doubt it. Add to this the fact that you can also go after localStorage and friends, you may have a bunch of data already.

When you get to the point where it is important to tweak every part of your performance stack (e.g. customer HTTP client and servers!) you will want to look at each interaction and think about:

  • What is important to show immediately?
  • What can we lazily load?
  • What should start low-res and then have us flip to high-res?
  • What can be cached?

Data Centers

Petabytes for the soul

It turns out it is faster for your machines in your data centers to talk to each other than for your customers to keep talking to the various machines.

You will want the edge to have as much of the data to send down to the client in a blast as possible. Chattiness over networks (especially mobile ones) are not your friend.

You Already API

We have been through the years where the “web site doesn’t have an API for mobile yet!” They aren’t pretty. We got through them though and now you probably have nice APIs that multiple clients can access. Having all of the clients use these APIs is important. If you have a “mobile API” and the desktop web site doesn’t use it, I bet money that the ideal feature parity isn’t available :/

Beware perverted incentives.

Motion

The bar for a consumer grade experience is always getting raised. Motion, animation, and feedback are really important. When the customer goes between Web and native their worlds are blurring, thus more motion and layering will come to the Web and this fits in nicely with fluid SPAs.

The Web has an advantage in that the “app” can be downloaded and changed all the time. This allows for great A/B testing, seamless updates, but also requires the downloading of the app (vs. having the beast already on the device).

As your experience grows you want to have a build system that has a small core that is one step ahead of the customer.

Compare facebook.com to the Facebook app. A lot of code ships in that app that will never be run by a large number of users.

You can also look at the Google iOS app. That search box comes in at 64.7MB! (I know it is a LOT more than a search box). Smart dynamic loading is key, and this is one reason why I am excited about frameworks such as React Native that allow much more to be done at runtime.

Event driven

I a sucker for an event driven world. That REST thing can be over-rated at times. Why not think in state machines and events? With WebSocket support across native and Web it can be interesting to rethink how your application would work if it was connected in real-time…. but of course built to work very much offline first.

It drives me nuts when I see loaders all over the place when a lot of the data could be shown from cache.

Accessibility

Just as a datapoint, The WebAIM survey results (published yesterday) reveal 98.6% of screenreader users have javascript enabled.

Another area of concern for SPA is accessibility. There are a ton of nuances here, and it is an area that doesn’t get enough attention from teams, but I don’t think it is enough to icksnay SPA.

Other bots

Google isn’t the only bot out there man! There are Gobots as well as Transformers!

Absolutely, and the others may not be as advanced on the JavaScript side as Google. I get it, but is it time to skate to where the puck is going?

Brave New World

As always, technology is advancing at a rapid clip. It is important to revisit your assumptions every year or two. There are no sacred cows.

How many Microsofties does it take to squish everything into Windows 10?

May 8, 2015 Leave a Comment


Do you remember Joel’s post from 2006 discussing how 24 people were involved in a trivial “Off” menu feature?

I was re-reading it (you can’t help but have a bit of a smirk as you do so) and thinking about the mammoth task at hand right now in Redmond.

Windows is an epic beast that has grown over decades. Now imagine taking the general large task of improving it and then adding the fact that each platform / fork needs to be merged for Windows 10. At a high level it is an easy thing to say:

“Look, we can’t have separate OSes for phone, embedded, desktop, server, Xbox, we need one experience to rule them all!”

Now imagine being the engineering teams. Think of all of the work that needed to be done to even understand what to do?

Each OS team understands their own world, and now they need to share and communicate that knowledge by mind melding with the other teams. Imagine all of the short cuts that were taken a long the way: “guys, we just need to fork that and make it work for Xbox… we gotta ship!” times a thousand.

This is a common pattern in the life of large projects. To move fast you want to minimize communication costs and have small teams with clear goals where the solution is mapped in their mind. If you get to a point where you want to converge the distinct efforts then the world stops as you collectively work out what to merge, what to scrap, and what to retool.

The more that you share and leverage, the more that you need to think about the abstractions; designing them to be flexible. You have to be better at predicting the future, which is really hard to do. At certain scales the standardization has been proven to be truly worth it (e.g. ARM, distributed systems on commodity hardware) but 99% of the time I have seen teams choose abstractions that were too restrictive and the so called leverage was wiped away with the communication and integration costs.

When you write code you tend to only refactor after the third usage. What is the appropriate equivalent for large scale abstractions?

One Platform To Rule Them All

Let’s say that there are three instances of a product. One path is to have three teams run at their own speed and write everything from scratch. They may choose to use the same low level stacks (e.g. they all use node running on AWS) and differ on others (some use PostgreSQL, Redis, React on the front end, others go with other options). Each team runs at full pace, but get no leverage from each other.

On the other end of the scale one team builds a full platform that has all of the features required for the three different products. Now you get to share a lot more, but you also have much pain in that the platform needs to fully morph. This approach can be great if the three products are very similar, but it can be awful if there are many differences. Once up and running you also need to work out how to prioritize across the products. If they aren’t balanced then it is very easy to end up with one product that is the most popular owning the bulk of the back log. In that case it sucks to be the other two. It can help to dedicate resources to each product, but then you are splitting on people resources vs. backlog work.

Apple and Microsoft

Windows 10 isn’t the only operating system in this dance. iOS was born in classic Apple style. A team was formed to go after the mission. They could steal people. They fork and run.

I have also heard that the org structure has changed a lot in the last few years. Consolidation has happened (e.g. one power management team to support iOS and OS X).

I don’t know about you, but I have felt like my recent Apple products have been less stable (both iOS and OS X). Is this just the weight of product development? It does feel like the teams are being pushed too hard. Those yearly releases must be brutal! But, I also wonder if part of the issue is pivoting to a more shared world.

One Adaptive World

Why is this work happening at the same time? You can see the argument:

It is time to have one adaptive computing platform. A unified experience. A unified store. The future isn’t a desktop and a phone. The future is connecting together inputs, compute, storage, and outputs.

This makes sense to me. My “phone” is a small scale compute, storage, inputs and outputs that are always with me, and it can connect to various external accessories to allow me to do more. Microsoft HoloLens (a.k.a 3d Bob!) is a glimpse to one aspect of another world of extensibility.

The future is exciting. Hopefully it won’t be the external dystopia of Ready Player One (I can’t wait to see the movie when it comes out!), but something greater outside of the matrix.

As we continue to build this future at an accelerating rate I will raise a glass to the engineers and teams who are having to go through grueling hard work to get there. Getting to the vision of Windows 10 is going to be a massive task, with beasts at every turn. These teams must be working on huge refactoring and rebuilding right at a time that there is intense pressure to ship cool new features and products.

My hat is off to you. Your companies future depends on you. Hacking on v1 is the easy part. What you are doing is the real work. The good news is that it has been done before.

Good luck.

« Previous Page

Primary Sidebar

Twitter

My Tweets

Recent Posts

  • Stitching with the new Jules API
  • Pools of Extraction: How I Hack on Software Projects with LLMs
  • Stitch Design Variants: A Picture Really Is Worth a Thousand Words?
  • Stitch Prompt: A CLI for Design Variety
  • Stitch: A Tasteful Idea

Follow

  • LinkedIn
  • Medium
  • RSS
  • Twitter

Tags

3d Touch 2016 Active Recall Adaptive Design Agile AI Native Dev AI Software Design AI Software Development Amazon Echo Android Android Development Apple Application Apps Artificial Intelligence Autocorrect blog Bots Brain Calendar Career Advice Cloud Computing Coding Cognitive Bias Commerce Communication Companies Conference Consciousness Cooking Cricket Cross Platform Deadline Delivery Design Design Systems Desktop Developer Advocacy Developer Experience Developer Platform Developer Productivity Developer Relations Developers Developer Tools Development Distributed Teams Documentation DX Ecosystem Education Energy Engineering Engineering Mangement Entrepreneurship Exercise Eyes Family Fitness Football Founders Future GenAI Gender Equality Google Google Developer Google IO Google Labs Habits Health Hill Climbing HR Integrations JavaScript Jobs Jquery Jules Kids Stories Kotlin Language LASIK Leadership Learning LLMs Lottery Machine Learning Management Messaging Metrics Micro Learning Microservices Microsoft Mobile Mobile App Development Mobile Apps Mobile Web Moving On NPM Open Source Organization Organization Design Pair Programming Paren Parenting Path Performance Platform Platform Thinking Politics Product Design Product Development Productivity Product Management Product Metrics Programming Progress Progressive Enhancement Progressive Web App Project Management Psychology Push Notifications pwa QA Rails React Reactive Remix Remote Working Resilience Ruby on Rails Screentime Self Improvement Service Worker Sharing Economy Shipping Shopify Short Story Silicon Valley Slack Soccer Software Software Development Spaced Repetition Speaking Startup Steve Jobs Stitch Study Teaching Team Building Tech Tech Ecosystems Technical Writing Technology Tools Transportation TV Series Twitter Typescript Uber UI Unknown User Experience User Testing UX vitals Voice Walmart Web Web Components Web Development Web Extensions Web Frameworks Web Performance Web Platform WWDC Yarn

Subscribe via Email

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

Archives

  • October 2025
  • September 2025
  • August 2025
  • January 2025
  • December 2024
  • November 2024
  • September 2024
  • May 2024
  • April 2024
  • December 2023
  • October 2023
  • August 2023
  • June 2023
  • May 2023
  • March 2023
  • February 2023
  • January 2023
  • September 2022
  • June 2022
  • May 2022
  • April 2022
  • March 2022
  • February 2022
  • November 2021
  • August 2021
  • July 2021
  • February 2021
  • January 2021
  • May 2020
  • April 2020
  • October 2019
  • August 2019
  • July 2019
  • June 2019
  • April 2019
  • March 2019
  • January 2019
  • October 2018
  • August 2018
  • July 2018
  • May 2018
  • February 2018
  • December 2017
  • November 2017
  • September 2017
  • August 2017
  • July 2017
  • May 2017
  • April 2017
  • March 2017
  • February 2017
  • January 2017
  • December 2016
  • November 2016
  • October 2016
  • September 2016
  • August 2016
  • July 2016
  • June 2016
  • May 2016
  • April 2016
  • March 2016
  • February 2016
  • January 2016
  • December 2015
  • November 2015
  • October 2015
  • September 2015
  • August 2015
  • July 2015
  • June 2015
  • May 2015
  • April 2015
  • March 2015
  • February 2015
  • January 2015
  • December 2014
  • November 2014
  • October 2014
  • September 2014
  • August 2014
  • July 2014
  • June 2014
  • May 2014
  • April 2014
  • March 2014
  • February 2014
  • December 2013
  • November 2013
  • October 2013
  • September 2013
  • August 2013
  • July 2013
  • June 2013
  • May 2013
  • April 2013
  • March 2013
  • February 2013
  • December 2012
  • November 2012
  • October 2012
  • September 2012
  • August 2012

Search

Subscribe

RSS feed RSS - Posts

The right thing to do, is the right thing to do.

The right thing to do, is the right thing to do.

Dion Almaer

Copyright © 2026 · Log in

Loading Comments...