All My Best Debugging Tips
This is a list of all the best debugging tips I’ve picked up over the years. Some of these might seem obvious, yet we forget them when it counts. Debugging is a skill. You have to bring every tool you have to the job.
Tmux Application Startup Script
My development environment depends on several processes running. Here’s how I’ve scripted this setup.
Recognizing and Repairing a Broken Mental Model
Perhaps you’re familiar with this scenario: you’re debugging and stuck. You’ve Googled, read some blog posts and docs. You return to your search engine, type some characters, and then something strange happens: the search engine autocompletes your question, and the results are all purple because they have been visited by you. I’ve come to recognize this moment as always a symptom of a broken mental model.
Retros Need Action Items
Action items are small, defined, actionable TODOs to follow up on after the meeting. An example: “close all pull requests opened more than 90 days ago.” Agile retrospectives should produce many of these.
Better Than 'foo'
There’s almost always a better variable name or value than ‘foo’. It’s useful as a debugging placeholder, but it almost never belongs in production code, even and especially in automated tests.
Database Migration Checklist
I think a great migration database migration is: correct, atomic, reversible, consistent with the style of the application, and (mostly) uncoupled from your application and RDBMS.
Logging an Object in JavaScript
When printing a JavaScript value to the console, I suggest using an object literal over the raw value.
What Are the Tradeoffs of Passing Objects as React Props?
A common React pattern is to pass an object as a prop. Let’s consider the ways this can be used and tradeoffs of each.
Naive Implementation: The Art of Artless Programming
A naive implementation is a programming technique that prioritizes imperfect shortcuts for the sake of speed, simplicity, or lack of knowledge.