from Hacker News

Ask HN: Whatever Happened to Progressive Enhancement?

by louissan on 4/20/22, 1:50 PM with 5 comments

In a world now (overly?) populated with SPAs, SSR/CSR and whatnot, what happened to this (traditional?) (outdated?) (still very much valid?) technique/tradition?

<hyperbolic>Has Javascript finally killed Javascript? :-)<hyperbolic>

It is a question I have a hard time translating into words but hopefully, dear HN, your discussion and insight can enlighten me.

  • by seanwilson on 4/20/22, 4:12 PM

    This won't be popular, but only a tiny minority of users have JavaScript disabled (~0.5% to 1.5%, https://www.mediawiki.org/wiki/No-JavaScript_notes) and many page interactions and third party services require JavaScript (forms, animations, pop-ups, payments, captchas, logins) so why would companies invest budget into progressive enhancement and adding that on top of already tedious cross-browser testing?

    I'm not saying it's right or wrong, but this has never been on the radar let alone seen as important with any clients wanting websites that I've worked with, the same way most aren't going to prioritise Internet Explorer support for ~2% of users (https://kinsta.com/browser-market-share/). Non-tech people and many developers don't even know what this is and most likely have JavaScript enabled themselves so it's going to be a hard sell, especially when they see their popular competitors have JavaScript heavy websites.

  • by open-source-ux on 4/20/22, 5:31 PM

    Progressive Enhancement is practiced by (some) public-funded organisations. These organisations have a public duty to serve as wide as a audience as possible. I don't know if these Progressive Enhancement websites are in a minority or not, but it's disappointing if they represent a minority.

    Progressive Enhancement website examples:

    GOV.UK

    The UK government website (gov.uk) use Progressive Enhancement and even have guidelines: Building a resilient frontend using progressive enhancement (Last updated 2019): https://www.gov.uk/service-manual/technology/using-progressi...

    From the article guidelines above:

    > Progressive enhancement is a way of building websites and applications. It’s based on the idea that you should start by making your page work with just HTML, before adding anything else like Cascading Style Sheets (CSS) and JavaScript.

    > This is because HTML is the most resilient layer. If the HTML fails there’s no web page. Should the CSS or JavaScript fail, the HTML will still render correctly.

    ---

    BBC News website

    I just tried the BBC News website (bbc.co.uk/news) and it works without JavaScript (for UK visitors).

  • by smt88 on 4/20/22, 1:59 PM

    You seem to be talking about building sites that work with JavaScript disabled, which is a part of progressive enhancement but not all of it. Progressive enhancement is still very much an issue in a world of endless browser permissions and a variety of web-enabled hardware.

    As far as sites without JS, there just isn't really a profit motivation. The vast majority of the web is one of two things:

    1) "free" but monetized by ads

    2) subscription-based

    In the cases of #1, it's almost impossible to effectively serve ads without JavaScript. You have to track conversions to make any money at all, and tracking is hard to do on the server side.

    In the cases of #2, you often need to deliver SPA-like features that are only possible with JavaScript, so you just expect your users (who have already jumped over the payment hurdle) to enable JavaScript to get what they paid for.

    Any other categories of sites are vanishingly rare.

  • by PaulHoule on 4/20/22, 2:23 PM

    I remember in the mid 00's many of the web design shops in town were developing applications on Ruby on Rails which codified a set of conventions for building "real" applications on top of web forms: particularly the reification of form elements as something that exist on both the client and server and the ability to render one of several different "views" in response to a form submission. (e.g. show either the next page after a form submission or re-render the same page with an error message if it fails validation.)

    Not long after I saw the same people were struggling with Angular and they were telling me that their customers only wanted to pay for SPAs.