Is progressive enhancement still a thing?

(Daniel Hollands) #1

I’ve been involved in the web for a long time, and in that time a lot of things have changed. It went from using tables for layout to floated DIVs (and soon to flexbox) for layout, from <font> tags to CSS styling, and from server-side everything to JS-only frameworks.

In all of this change, a process known as progressive enhancement was adopted by a large number of developers. This worked on the idea of ensuring that all users of your site, regardless of the technology they used (be it an old broken down version of IE, or the very latest copy of Chrome) should be able to use the site to one degree or another.

AJAX is a good example of where progressive enhancement would be beneficial. This is because AJAX requires JavaScript, so if a user with JavaScript disabled tries to use an AJAX only site, they’re out of luck. To fix this, you’d ensure that your site works with both AJAX and regular POST requests.

Anyway (getting to the point) I’m interested in your views on progressive enhancement, and if you still practice it? If you’re a JavaScript developer, what steps do you take to ensure non-JS folk can use your stuff (or do you not bother?)

(Jim Gumbley) #2

From my perspective I think its one of those things that has just been rolled into business as usual, like continuous integration, continuous delivery and increasingly devops.

People don’t talk about it, they are just doing it, at least on the projects I work on.

That said there is an antipattern I see in less experienced teams of just layering cool JS framework on top of cool JS framework without regard to accessibility and browser requirements, and then suffering a panic point when real users struggle to use their site.

This is softened somewhat by improving client devices, modern tablets, phones and increased use of up to date browsers. Even with that said - its something that happens.

That said if you are developing an internal facing application where you can make good assumptions about the client devices (i.e. corporate estate where everyone has XYZ browser) then building a rich single page app which will never load on IE6/7 is possibly a tradeoff worth making…

(Michael Brett) #3

Great article about progressive enhancement by Jake Archibald (a genuine web don, IMO)

Progressive Enhancement is Faster

(Michael Brett) #4

Also, didn’t @sil rock a post about JavaScript being turned on (or not) recently?

(Stuart Langridge) #5

That would be indeed!

(Andy Wootton) #6

As someone who has worked in a company using IE V.embarassing, I think devs have a duty to clearly signal periods of obsolescence for technologies if there is to be any real progress. takes at least 2 years to plan an upgrade but their staff need evidence to force them to do it.

Horses aren’t allowed on the motorways.

(Michael Brett) #7

Just came across this article via CSS Tricks that is pertinent to this debate.

The End Of Global CSS

Surely this violates separation of concerns? But then like the man says, we aren’t living in as much of a document based web anymore …

(Michael Brett) #8

If you haven’t heard it yet, a really impassioned defence of progressive enhancement from Andy Budd on the ShopTalk show:

Definitely worth a listen:


(Jon) #9

Related to this, does anyone know of a JavaScript frontend framework that it is well-suited to progressive enhancement? I’m considering using something like Angular on my current project but I’d like the basic site to work without JavaScript.

I’ve only used a bit of Angular; I guess I’d build the basic app and then layer the ‘MVC’ JS approach on top, and I wonder if there is an architecture/library that lends itself more to this than another? I know in Angular, custom attributes are used in the HTML to indicate what control is bound to what feature - I guess this is just ignored if JS is disabled?

All that said, I do wonder whether one is effectively designing two apps here - buttons need to be anchors in an MVC JS app, and real links or post actions in a traditional page round-trip model. For those here who use these sorts of frameworks, is it worth the hassle?

(Jim Gumbley) #10

I still prefer writing a really solid server rendered UI first then enhancing with Javascript only when necessary.

Tends to be React or JQuery, D3 if visualisations that ends up of use.

Angular will take over the entire app, its a framework not a library.

(Jon) #11

Thanks Jim, I think I’ll do the same. I’m using jQuery at present, though I find it tends to sprawl a bit in larger apps! I should split it into classes and create a better build process.

I don’t know React, but just took a peek - interesting. It says it can be used piecemeal to enhance existing apps, and so looks much easier to try than Angular. I might give it a whirl.