A service that works better for everybody: Supporting more users with gracefully degrading React
Using modern technologies can make development faster, but ultimately we need to deliver working solutions without sacrificing robustness or accessibility. We’ve built the “Reschedule a citizenship test” service in a way that pushes service delivery forward without leaving users behind.
A robust service benefits all users
Given the abundance of internet-connected devices, it isn’t possible to predict the complete set of browsers that will end up viewing your website. In many cases, this leads to building interactions that work for some people but fail for others — not a good outcome for a government service.
Progressive enhancement and graceful degradation are approaches that can be used to build a service that prioritizes inclusiveness. These are different paths to the same destination: building extremely robust web services that succeed on the broadest possible range of devices. In both cases, the goal is a service everyone can use: more capable devices get an enhanced experience, less capable ones see a more basic interface.
Progressive enhancement calls for starting with a basic experience and improving it.
Graceful degradation means building the enhanced experience first and then backfilling behaviour where needed.
When designing government services, public servants have a responsibility to support those who need it most. This is why progressive enhancement is a principle commonly followed by government digital agencies in the UK and New Zealand, for example. As the brilliant Alice Bartlett said in her “Burn your select tags” conference talk: “we have to serve the needs of an entire country interacting online with its government”. She includes people who can only access the internet in a library, low technical-confidence users, and people who rely on screen-readers and other assistive technology. These are not edge cases: our service needs to work for everybody, and this is why we have built a citizenship rescheduling service that gracefully degrades.
The tradeoff of building sites using modern technology
While modern tools and newer syntax can greatly improve the experience for web developers, they often result in sites that are less robust for users, as they cannot reliably be used on older devices.
Before we had any real users, we prioritized building out the service quickly, testing it, and iterating on it. In our early stages, with a fairly volatile codebase, it would have been too early to try to solve everything at once. As Jason White, erstwhile Head of Data, was fond of saying: “premature optimization is the root of all evil”.
Once we had a good understanding of what our service would look like, we prioritized backfilling it to support older clients, which also improved it for everyone else.
Thanks to graceful degradation:
- users can load the site in either official language
- users don’t lose saved information when they refresh the page
- users don’t lose their language preference if they close the site and return later
- users whose devices can’t run our code can still reschedule their appointments
- the site loads faster for everyone
For the technically-minded, we’re writing a follow-up post about how it works, but the key point here is that graceful degradation has made our service better. It works for users with restrictive firewalls. It works for assistive technology that expects content when the page first loads. It even works on devices we’re not explicitly supporting — for instance, I can reschedule a citizenship appointment on my Nintendo 3DS.
The best of both worlds
Granted, our solution isn’t the panacea: not every product is this product. However, it is a statement of principle, and we are extremely proud of having done the hard work to make it simple. Our service solves an important problem for our users, it is simple to use, and it works on your Game Boy.