web application – When to use Graceful Degradation and when to use Progressive Enhancement?

Question:

When creating a website or web application, there is always the problem of what to do when not all browsers implement all the desirable features. From what I've read, there are two main ways to deal with this:

  • Graceful Degradation – It is developed thinking about an environment as complete as possible, but ensuring that if the X or Y functionality is absent, the site still works as well as possible without it.
  • Progressive Enhancement ( Progressive Enhancement ) – It is developed thinking about the most basic environment possible, and it adds extra features if the presence of the X or Y functionality is detected.

What are the advantages and disadvantages of each of them? Are there situations where one is more suitable than the other, or is it just a matter of preference? I'm mainly interested in the maintainability aspect: as new features are introduced to browsers, and old versions of them fall into disuse, what are the implications of this for a website/application developed according to these strategies?

Answer:

technically there is no difference

With both approaches it is possible to implement compatibility with any browser, in any version. The difference between them is like a top-down or a bottom-up approach , but in the end you can achieve the same results.

Strategy can influence team mentality

For example, Graceful Degradation will somehow prioritize newer browsers, as the rationale is: implement the newest one, and if not, use plan B to maintain compatibility .

Progressive Enhancement, on the other hand, will produce the opposite effect, putting compatibility at the forefront: let's make it simple and, when possible, improve it a little .

Limitations That Matter

Unfortunately, today it is still necessary for us to do tests across different browsers and devices to really ensure a system is functioning properly. And I believe it's inevitable that the team ends up focusing on the functions most immediate to its reality.

So we are faced with two restrictions:

  • The developer will prefer a specific environment to code in, which inevitably increases the chance of errors in the "secondary" environments that he has had less contact with.
  • The limitation of time and resources makes it impossible to carry out adequate test batteries in all possible scenarios.

Conclusion

With all of this, my conclusion is that a browser's feature detection technique (or lack thereof) is no more important than correctly defining a development and testing strategy.

As in general you cannot have everything, then a clear definition of the target audience and the most likely scenarios for using the system is necessary.

If the trend is for users to use more modern browsers, then it's more worthwhile to start by taking on the newest functionality. When the browser does not have some functionality, Mild Gradation is applied. If there is any problem, it will at least reach the minority of users.

In another scenario, imagining perhaps a government agency or a large company, where the updating of browsers is going very slowly, it is better to use less of the new features and, in certain scenarios, it is possible to enrich the system. Likewise, few users will be impacted if there is any problem because of this.

Scroll to Top