What is the purpose of the web?
Morten Rand-Hendriksen
AI & Ethics & Rights & Justice | Educator | TEDx Speaker | Neurodivergent System Thinker | Dad
Over the weekend, Sindre Sorhus tweeted a screenshot of some HTML:
What followed was a massive distributed conversation about the role of JavaScript, frameworks, task runners, automation, and tooling in general on the web, and whether the optimized web is making the web a better or worse place. (Read the responses to that tweet to get a better picture of the conversation.)
This debate is a variant of several conversations which have raged in the front-end web community for the past year or so around the role of the "front-end" developer and the tools they use in building the modern web. Other variants include "Is CSS-in-JS good or bad", "Can BEM SmaCSS ITCSS?" and "React is the best thing ever / destroyer of worlds" etc.
This bikeshed is old btw. But I digress.
The web's purpose
For me, the most striking and on-point injection to this larger conversation came from Jen Simmons in a Twitter thread:
Simmons' analysis puts the finger on something I think a lot of us have been feeling for a long time (I know I have) about the tools we use, the trends we follow, and how they are shaping the web in a direction I'm not sure I am comfortable with.
Let me explain (this is all stream of consciousness btw. Don't expect any major and well-thought-through ideas to emerge from my ramblings):
To me, the web is a democratic publishing platform. To put your thoughts, ideas, and creations onto the web and allow others to share in them, all you need is a stable internet connection and a perfunctory understanding of HTML (or the ability to augment a boilerplate). This, I think, is what both Sorhus and Simmons are referring to (correct me if I'm wrong). If we believe this is the purpose of the web, we must act to preserve it.
The code pictured in Sorhus' original tweet is the antithesis of this idea: It is semantically unsound markup suffering from a severe case of divitis, paired with large volumes of generated classes derived from computer barf.
How did the developer end up here? Through the use of automated process to optimize the code to make it as fast as possible (though I doubt this particular example is fast at all).
Now here's the thing: Using developer tools like code optimizers, minifiers, etc is not a bad thing. What is problematic is when those tools are used in excess and with a sole focus on performance over semantics. Why is that a problem? Because the web should be resilient meaning if JavaScript and CSS and everything else fails, you should still be able to parse the content and derive the information within from it. That's what HTML is for: Adding semantic context to information. What we see in the example provided is code adding computing context to information, and obscuring the information in the process.
Why is that a problem? Isn't optimizing code for the web a good thing? Not if you care about the democratic element of the publishing platform. If we write our code to please computers, the people who build browsers for computers will start favoring that type of code and tell us to write better code for computers. Which will result in semantics going the way of the dodo in favor of a highly optimized electric sheep.
I think all these conversations are really variants of the same question: What is the purpose of the web, in the past, now, and in the future? As I see it, the first 15 or so years of the web showed us the web as a publishing platform. Today we are in a transitionary phase where part of the web remains a publishing platform while the other part is an application framework. If we follow this trend, the publishing platform aspect will wane into obscurity while the application framework model will win out.
If so, the question we must ask ourselves is whether this is the path we want to lead our users down, if this is the future we want to build for ourselves.
I think the value of the web is in its purpose as a democratic publishing platform. I'd love to hear your thoughts.
--
Morten Rand-Hendriksen is a Senior Staff Instructor at LinkedIn Learning (formerly Lynda.com) focusing on front-end web development and the next generation of the web platform .
Designing, building, and sustaining enterprise WordPress solutions.
6 年Some people have been predicting we'll end up with a new eastern vs. western bloc version of the internet. And within those, why not the machine web layer and the human-readable layer for literate people who still think and communicate in writing??
Website, Graphic Design & Digital Marketing Expert
6 年Reading your article just made me want?Richard Hendricks and the team at Pied Piper to finish their New Internet!