DEV Community

Discussion on: What can a backend dev do to improve Accessibility?

Collapse
 
alvaromontoro profile image
Alvaro Montoro • Edited

These are more general development/usability ideas, but they may impact accessibility:

I'd say handling errors graciously. If there's an error, don't just crash and die, handle and recover from exceptions, provide information to be handled by the front-end. Having an app close without a message, or getting a blank web page without information is bad for everyone. Good and verbose communication between front-end and back-end will set up an environment that handles accessibility better.

Also, designing/managing the data with accessibility in mind and ready to adapt. For example, normalizing your database to support the internationalization of text, or being flexible with the data types you use (e.g. the classic "use varchar instead of number for a phone number" because you may get it in different formats).

Another one would be stop assuming all the work is/was done by the front-end. It doesn't matter how fancy the front-end is, there will always be users who interact in a different way or with a different browser. Some –if not all– of the data processing and validation that is done in the front-end will have to be done in the back-end too to provide a better experience (and for security too!)

Collapse
 
vickilanger profile image
Vicki Langer

I agree. We shouldn't assume accessibility is just a front-end thing. Giving good error messages can definitely be helpful.

The front-end is like a storefront, while the back-end is like the shelves with products on them. It's necessary for the storefront to have a ramp and handicap parking. It's equally necessary that things are accessible in the store too.

Collapse
 
pclundaahl profile image
Patrick Charles-Lundaahl

All fantastic points! I think the last paragraph, in particular, is really poigniant, and contains at least a couple of sub-points:

  1. Whatever work you can do on the server, or ahead-of-time, do it. Not everyone can afford current-gen smartphones, and modern JavaScript frameworks basically demand decent specs. If you can forego that in favor of traditional server-side rendering, I really think you make things more accessible (also, probably worthwhile to ask your frontend devs to try using CSS for animations first, before resorting to JS).

  2. If at all possible, develop API-first. This paves the way for doing things like providing voice assistant interfaces to your website/app. I think most people probably do this already, but I also think it doesn't hurt to say it again!