User agents
Tags: browsers, frontend, development, learning
Published: 2020-05-13 18:57:38

---
title: User agents
published: true
date: 2020-04-30 17:08:25 UTC
tags: browsers,frontend,development,learning
canonical_url: https://adactio.com/journal/16832
---

[I was on the podcast A Question Of Code recently](https://aquestionofcode.com/60-what-is-a-resilient-website-jeremy-keith/). It was fun! The podcast is aimed at people who are making a career change into web development, so it’s right up my alley.

I sometimes get asked about what a new starter should learn. On the podcast, I mentioned [a post I wrote a while back](https://adactio.com/journal/15782) with links to some great resources and tutorials. As I said then:

> For web development, start with HTML, then CSS, then JavaScript (and don’t move on to JavaScript too quickly—really get to grips with HTML and CSS first).

That’s assuming you want to be a good well-rounded web developer. But it might be that you need to get a job as quickly as possible. In that case, my advice would be very different. I would advise you to learn React.

Believe me, I take no pleasure in giving that advice. But given the reality of what recruiters are looking for, knowing React is going to increase your chances of getting a job (something that’s reflected in the curricula of coding schools). And it’s always possible to work backwards from React to the more fundamental web technologies of HTML, CSS, and JavaScript. I hope.

Regardless of your initial route, what’s the next step? How do you go from starting out in web development to being a top-notch web developer?

I don’t consider myself to be a top-notch web developer (far from it), but I am very fortunate in that I’ve had the opportunity to work alongside some tippety-top-notch developers at [Clearleft](https://clearleft.com/)—[Trys](https://www.trysmudford.com/), [Cassie](https://www.cassie.codes/), [Danielle](https://twitter.com/dhuntrods), [Mark](http://allmarkedup.com/), [Graham](https://gablaxian.com/), [Charlotte](https://www.lottejackson.com/), [Andy](https://andyhume.net/), and [Natalie](http://natbat.net/).

They—and other top-notch developers I’m fortunate to know—have something in common. [They prioritise users](https://adactio.com/journal/16811). Sure, they’ll all have their favourite technologies and specialised areas, but they don’t lose sight of who they’re building for.

When you think about it, there’s quite a power imbalance between users and developers on the web. Users can—ideally—choose which web browser to use, and maybe make some preference changes if they know where to look, but that’s about it. Developers dictate everything else—the technology that a website will use, the sheer amount of code shipped over the network to the user, whether the site will be built in a fragile or a resilient way. Users are dependent on developers, but developers don’t always act in the best interests of users. It’s a classic example of [the principle-agent problem](https://en.wikipedia.org/wiki/Principal%E2%80%93agent_problem):

> The principal–agent problem, in political science and economics (also known as agency dilemma or the agency problem) occurs when one person or entity (the “agent”), is able to make decisions and/or take actions on behalf of, or that impact, another person or entity: the “principal”. This dilemma exists in circumstances where agents are motivated to act in their own best interests, which are contrary to those of their principals, and is an example of moral hazard.

A top-notch developer never forgets that they are an agent, and that the user is the principal.

But is it realistic to expect web developers to be so focused on user needs? After all, there’s a whole separate field of user experience design that specialises in this focus. It hardly seems practical to suggest that a top-notch developer needs to first become a good UX designer. There’s already plenty to focus on when it comes to just the technology side of front-end development.

So maybe this is too simplistic a way of defining the principle-agent relationship between users and developers:

`user :: developer`

There’s something that sits in between, mediating that relationship. It’s a piece of software that in the world of web standards is even referred to as a “user agent”: the web browser.

`user :: web browser :: developer`

So if making the leap to understanding users seems too much of a stretch, there’s an intermediate step. Get to know how web browsers work. As a web developer, if you know what web browsers “like” and “dislike”, you’re well on the way to making great user experiences. If you understand the pain points for browser when they’re parsing and rendering your code, you’ve got a pretty good proxy for understanding the pain points that your users are experiencing.