This issue of my newsletter was sent to newsletter subscribers.
Sign up to receive future issues!
Hi there!
A couple of months ago, I shared my thoughts(opens in new tab) on the data from “The State of CSS”, an annual developer survey.
Well, the State of JavaScript 2024(opens in new tab) just published its findings, so I thought I’d do it again! In this newsletter issue, I’ll share the highlights, the things that I found particularly interesting or surprising. 😄
Let’s start with one of the most interesting questions in the whole survey: What proportion of the code you produce is AI-generated?
Here are the results:
Most of the respondents (80%) are using AI in their work, but they’re using it to fill in gaps. The overwhelming majority of respondents are still writing most of their code by hand.
This aligns with my own situation. I rely on Copilot as a sort of super-powered auto-complete, letting it finish my thoughts when the work I’m doing is predictable. And I rely on GPT-4 to help me make sense of funky TypeScript error messages, and occasionally generate short snippets. But ultimately, I’m still in the driver’s seat most of the time.
I saw a Forbes article(opens in new tab) recently about an announcement from Google CEO Sundar Pichai. He revealed that about 25% of new code being written at Google is AI-generated, piloted by software developers who write the other 75%. This number matches what we see in these survey results pretty closely!
It’s interesting to me because the main narrative for a while now has been that software development is on the cusp of being a solved problem. As AI gets better and better, it’ll soon hit the point at which a project manager with no coding experience can sit with a chatbot and develop new features in existing codebases, no programmers required.
I’ve written about my skepticism about this in my blog post, “The End of Front-End Development”(opens in new tab). I published that post almost 2 years ago now, and if anything, the time since has only strengthened my confidence. I think AI will continue to be a tool that developers use to augment their own skills, rather than an alternative to human developers.
As always, there’s a big difference between salaries in the US versus the rest of the world. Here’s what it looks like in the US:
And here’s everywhere else:
In the US, 77% of respondents are making six figures a year, with the median salary being US$175,000!
I was curious how this number compared to previous years, to see if developer salaries had kept pace with inflation. Unfortunately, the question format was different in previous years, with different salary bands presented as options, so it isn’t really possible to compare them.
But really, there are better data sources for this sort of quantitative analysis anyway! I decided to check with the US Bureau of Labor Statistics:
During the same 4-year period, cumulative inflation was 19.2%, so even in real terms, developer salaries have increased!
The US Bureau of Labor Statistics doesn’t yet have data for 2024, but fortunately, the Government of Canada just updated its data earlier this month! Here’s what I found:
Inflation during this 5-year period has been 18.6%, so developer salaries here have risen even more here in Canada. And interestingly, most of this increase has happened in the past 2 years (in November 2022, median salary was CA$83.8k/year).
I think people have expected developer salaries to decrease, given the rise of AI. But I actually think the opposite might be happening. Developers are more productive with AI tools, so doesn’t it make sense that our pay would rise with our productivity?
I don’t mean to paint too rosy a picture; the job market right now is tough, with lots of competition for every new listing. I also don’t want to read too much into this data, since it’s only a couple of data points for two countries. But my takeaway from all of this data is that things should get better for software developers, not worse.
This year, the State of JS survey started asking about job titles. It turns out there’s a significant salary difference between “developers” and “engineers”!
On average, a “software engineer” earns almost 2x as much as a “developer” ($90k vs. $50k). I’ve held both titles in my career, and as far as I can tell, it’s the same job 😅. So I guess if you’re looking to earn more cash, maybe start searching for “engineer” instead of “developer” on job sites, or change your title on LinkedIn?
(I should note, this can be tricky depending on where you live. Here in Canada, “engineer” is a protected title, like "doctor"; you need a specific license in order to use the term, and I think there are even potential legal consequences for impersonating an engineer.)
Alright, let’s actually look at some JavaScript stuff!
There weren’t a ton of surprises for me in this section, though I was a bit surprised to see that most developers (56%) haven’t used logical assignment operators!
I’ve been using these convenient little shorthands for years now:
a ??= 10;
// Equivalent to:
if (a === null || a === undefined) {
a = 10;
}
You can learn more about this in Operator Lookup(opens in new tab), my search engine for JavaScript operators and syntax.
Every year, the State of JS survey collects information on respondents’ experiences with JavaScript libraries/frameworks.
This chart looks pretty wild, with everything converging towards the center as though the graph has gravity:
The vertical axis represents usage, how widely-used something is. The horizontal axis is about sentiment, how people feel about it.
So for example, React is still the most widely-used front-end framework by a longshot, but its favorability has fallen quite a bit over the past few years:
Personally, I’ve been using React for almost a decade now, since early 2015, and I still think it’s the best tool for building dynamic web applications. But it does sorta feel like the honeymoon phase is over 😅.
I also wonder if maybe this drop in favorability is more about Next.js than it is about React? Check out this graph, which tracks positive sentiment about various meta-frameworks:
Next.js is the blue line that starts the earliest, in 2018. At its peak, almost 80% of developers had a positive sentiment about Next.js, but that number has now fallen below 60%.
I recently rebuilt my blog(opens in new tab) with the latest versions of React/Next. There’s some incredible engineering here, but also some very rough edges. I’ll be very curious to see how this sentiment changes as the technology improves; React’s upcoming compiler, for example, should hopefully address some of the biggest pain points for React devs.
Unsurprisingly, TypeScript has gotten even more popular:
In 2019, 40% of developers had never used TypeScript before. A few short years later, it’s not even a question anymore; we’ve all used it, and the question is whether we’re using it exclusively.
I think it’s interesting to compare this chart to the first chart in this newsletter, about the percentage of code which is AI-generated:
AI has become a pretty indispensable part of many developers’ toolkits, but it still has a long way to go before it catches up to TypeScript!
Those are the things that stood out to me, but this is just the tip of the iceberg. You can go through the data yourself(opens in new tab) to get a broader picture of this current moment in JavaScript history.
I have one more little thing to share with you today!
As some of you may know, I dealt with a really pesky nerve injury / RSI a few years back; for about 7 months, I couldn’t use a keyboard or mouse, and learned to code by voice(opens in new tab).
Fortunately, I don’t have any issues like that anymore. I can type as much as I want. Better still, I have zero fear of any future RSIs.
Lots of people have reached out and asked how I overcame these issues. I had a thread on Twitter all about this, but then it became inaccessible when I left Twitter last month. So I’ve just published a new blog post that builds on that thread and shares my story:
If you’ve dealt with a chronic RSI, I hope you’ll check it out! I obviously can’t make any promises about whether the same treatment will work for you, but I’ve heard from several people who have seen improvements following a similar strategy.
I know this is a very niche post that won’t be relevant for most of y’all, but I hope it reaches a couple of people who could benefit from it. ❤️
If you celebrate any of the winter festivities around this time of year, I hope you have very happy holidays. ❄️
See you in 2025!
This issue of my newsletter was sent to newsletter subscribers.
Sign up to receive future issues!
© 2018-present Joshua Comeau. All Rights Reserved.