Last week
- for (i = 0; i < numberOfElements; i++) { doSomethingWith(element[i]); } This works, but isn't very elegant. The Ruby way is much more elegant. elements.each do |element| do_something_with(ele...
- So I got an email earlier, which you’ll find out about in my next post, which made me think “hey, the reply to this would make a great blog post”, and then I thought “…and it would be even better if people could add their own comments to it”, and so I plugged in the rather...
- What a month! After losing a job at the end of January, I started looking for a new one straight away. Seeking a new job nowadays is very different from how it used to be. Very long, multi-step and mentally draining processes are the new norm. The recent explosion of AI tools...
- Pretext went viral for its beautiful canvas demos. But the community is showcasing the wrong feature....
Two weeks ago
- 1. Separate what you know once from what changes There is work that depends on data that rarely changes, and work that depends on data that changes constantly. When you mix them together, you pay the...
- A JavaScript engine (e.g. V8, JavaScriptCore) executes JavaScript code. It doesn't know about things like files, HTTP requests, or timers.On the other hand, a JavaScript runtime (e.g. Node.js, Bun) is a more complete environment where JavaScript runs. It contains a JavaScript...
- I shipped some updates to my notes site. Nothing huge. Just small stuff. But what is big stuff except a bunch of small stuff combined? So small stuff is important too. What follows is a bunch of tiny details you probably don’t care about, but they were all decisions I had to...
About a month ago
- Introduction This is the note for future me. This bug was not random. Chrome was correct. We tried to start background music from mousemove. That feels like usage. It is not a real activation event fo...
- Introduction You have a combobox using cmdk (shadcn Command component) inside a Radix Dialog. The list has more items than fit. You expect it to scroll. It does not scroll. You are not alone. This iss...
- Introduction Sonner is the best toast library for React. But the docs barely cover advanced styling. This is everything I learned building a custom dark toast system with colored rails, action buttons...
- This post is the fourth and last in a series comparing the same sample blog in Web Origami and Eleventy: - Eleventy version: Source code and Demo - Origami version: Source code and Demo As a very crude metric, the conciseness of legible code can roughly...
- This post is the second in a series comparing the same sample blog in Web Origami and Eleventy: - Eleventy version: Source code and Demo - Origami version: Source code and Demo Today let's look at how both projects define the overall structure of the site...
- March 17, 2026 This post series is for people who want to build or rebuild a site. You may have heard of Eleventy, a popular static site generator, and maybe heard it’s simple to use. To evaluate that simplicity, I’ll compare a sample blog in Eleventy to the same blog in Web...
about 1 month ago
- I’m interested in helping to create a shared JavaScript library for letting Electron apps authenticate with Netlify (and potentially GitHub/GitLab pages) via OAuth for the purpose of creating new projects and uploading files to existing projects.
- The Problem With a Fixed Textarea A normal has a fixed height. When content overflows that height, the browser adds a vertical scrollbar. This is fine for long-form editing like a notes app...
- Walking into London’s Barbican Estate is like stepping into a parallel timeline, a concrete vision of what the 1960s thought the future would look like. When people first encounter the term “brutalist”, the association that usually springs to mind is “brutal” – harsh, cruel,...
about 2 months ago
- Over the years, I’ve used different icon sets on my blog. Right now I use Heroicons. The recommended way to use them is to copy/paste the source from the website directly into your HTML. It’s a pretty straightforward process: Go to the website Search for the icon you want Hover...
2 months ago
- I upgraded kentcdodds.com from Remix v2 to React Router v7 in a day with over 17k lines of code changed. Here's how I did it....
- So I’m making a thing and I want it to be styled different if the link’s been visited. Rather than build something myself in JavaScript, I figure I’ll just hook into the browser’s mechanism for tracking if a link’s been visited (a sensible approach, if I do say so myself). Why...
- I used to pay $120/year for a SaaS that hasn’t added new features in four years, and didn’t fix its broken billing system for three years. Using an LLM, I managed to rewrite all the functionality I used to pay for in 20 minutes. Is this bad news for “write once, don’t update...
- In this article I want to share a technique that I recently learned to display an interactive map on a website. For this, you will need just a few lines of HTML and JavaScript. This solution does not require you to sign up for any accounts or services anywhere, it is completely...
- My blog uses aggressive caching: it sits behind Cloudflare with a 15 minute cache header, which guarantees it can survive even the largest traffic spike to any given page. I’ve …
3 months ago
- The rule of least power on the web incentivised using HTML before reaching for CSS, CSS before JavaScript, and bashing it into the JS script as a last resort. Every time the web ships new features that let us shift the implementation left on the stack, I’m excited about it. In...
- As I was playing around with contrast-color(), I got a wild idea that you could use contrast-color() to invert its return value by nesting it: contrast-color(contrast-color(var(--some-color)). When would this be useful? Uh… Good question. I couldn’t come up with an example right...
Rows per page