Articles
Software engineering lessons from production, raw and honest from the heart โ almost 20 years of them. Jump to a year in the sidebar, or browse categories and curated collections.
November 2022
What I learned from Staff Engineer by Will Larson
Staff Engineer was one of the more impactful books I've read in recent months. Went through the audiobook soon after becoming tech lead so the timing was perfect.
Reader question: useReducer or XState?
Following up from my article about XState and Stately.ai, fellow reader S. asked if `useReducer` could ever be relevant when using state machines in React code. Yes! Here's how
When your brain is breaking, try Stately.ai
Two years ago I wrote about using XState after building a UI interaction so twisted my brain leaked out my ears. It helped. Now the creators have made something even better โ Stately.ai ๐
On becoming tech lead
A few weeks ago I made tech lead, a type of staff engineer. Here are my thoughts on what that means, how it happened, and why you'd want such a thing.
October 2022
Why PATCH endpoints matter
A painful lesson from production that brought several engineers almost to tears: *Please* add PATCH endpoints to your public APIs.
Over-engineering tweet embeds with web components for fun and privacy
A way to embed tweets in static sites with full pre-renders and live updates using just 9kB of client-side JavaScript, 2 HTTP requests, and full reader privacy โ๏ธ
Reader question: Work at a big international or a local studio?
Fellow reader Frank writes in with a question about career moves and I thought my answer could help you too
Grow your career ... in this economy??
if you've been following tech news lately, things feel ... ๐ Between the layoffs, hiring freezes, investors suddenly caring about revenue, and whatever the heck stock markets are doing, we're in for a rough time. BUT!
September 2022
How better data modeling fixes your code
When your code feels hard, 9 times out of 10, the problem is with your data model. The signs are subtle.
Reader question: Should you learn the latest hotness?
Great question. Common concern. *What if I get stuck in a technology that isn't hot??* Or worse, burn out re-learning every new thing ๐ฑ
Notes on A Relational Model of Data for Large Shared Data Banks
In 1970 a paper came out that changed the world of business computing. It laid the ground work for modern databases.
useCallback is a code smell
One of my favorite ways to simplify and de-gotcha React code is to rip out all the useCallback and useMemo drama. 90% of the time you don't need it.
The art of the cowboy merge ๐ค
how do you catch a critical deadline that cannot be missed? We're talking external stakeholders, millions on the line, and it all hinges on *your* team getting it done on time. No overtime
If it works together, it lives together
Wherein I use LEGO to talk about organizing your code for ease of use
Why others' code is hard to navigate
Some people like to organize code in files and folders and neat categories. Others love search. When they work together, that's the challenge.
August 2022
Reader Question: What do collaborative teams look like?
New members on our team invariably say 2 things: 1. Wow I've never seen a team move this fast 2. This approach feels weird. I'm uncomfortable Teams like this are not common.
What makes a real image?
What does a real image look like? The rise of modern AI photo editing and generation tools makes this an interesting question.
Your code doesn't matter
"Your code doesn't matter" is something experienced programmers say, between the lines, when they sound like complete lunatics. But what do they mean? Why does everyone say it?
What coding tutorials and teachers get wrong
Chatting about teaching and learning complex technical skills with an engineer I'm mentoring. She's a former chef. We shared the same frustration with online resources.
I stopped using Google Analytics after 15 years
swizec.com has been around since 2005. For 15 of those years, it's been running Google Analytics to give me a sense of "Is anyone out there?". No more.
Reader question: So about that perfect burndown chart ...
If your approach works so well, why isn't every team doing this?
Move your business logic into data
The quickest way to simplify a complex function with lots of logic is to turn it into data. A lesson from production
July 2022
Nobody is coming to save you
How do you react when you don't like The Process at work? Most programmers complain on social media, make a wry joke, and ... suffer. Not great
You do have time to build it twice
My talk from React Summit is now online, if you're curious. It's about code rewrites in the context of hyper growth startups. The ultimate sin. Or is it ๐ค
Reader question: Feeling guilt as a tech lead
Keep getting the guilt, that I'm not able to code, just running around for discussions and solving other issues, managing people. Any idea to manage all the fronts and get rid of this guilt?
You don't *have to* build it sloppy to go fast
My favorite mistake to make when I'm in a hurry is to think that I _have to_ build new features the sloppiest way possible. Find the quick fix and move on. But that's not true.
A work ritual that keeps me sane
A coworker asked me for tips on how to stay focused during the day. Here's what I said.
What makes a great software engineer?
In 2015 a group of researchers asked 59 experienced engineers at Microsoft "What makes a great software engineer?". Here's what they found.
Write abstractions, not just code
Wherein I use a silly example to show why you need more than small reusable single purpose functions to write good software.