Cat logomenu


page 2

My wife is away for the week, so this mope has to put up with me as a substitute for her favorite person.

My labradoodle Luna resting her head on my knee pathetically while we sit on the couch together

March 19, 2023

Programming, Tutorials

Build a Modern GraphQL API with Prisma

Learn to use Prisma, a powerful, type-safe ORM to build a modern GraphQL API in this new course by Ryan at Level Up Tutorials

September 30, 2021

Winona Lake — Night

Park Avenue & Administration Boulevard, looking southward

Light Rail Café & Roaster from the foot of 9th Street Hill

Cerulean Restaurant & Beer Garden

Map of the Village outside Cerulean Restaurant, its light enveloped by a cloud of bugs

Light Rail Café & Roaster, seen through the trees across Park Avenue

K21 Health Foundation building

Historic Winona Lake Fountain

View up 12th Street hill from Park Avenue

Sunday Lane alley, from near its entrance onto 12th Street

Sunday Lane as it starts to run downhill toward Oak Street

House at the intersection of Sunday Lane & Oak Street

July 5, 2021

small handmade wooden shelf with some personal items, including the collected works of Lewis Carroll

I’m starting to realize about myself that I’d rather have something personal, nostalgic, or imbued with special meaning, than something that looks perfect or perfectly matches my taste. Sally made this when she was a kid, in some shop class or other. Not great craftsmanship, not great materials, not even a particularly interesting design. I could have bought myself something prettier, nicer, and more functional to serve this purpose. But I never even more than briefly considered it. I’d rather have this.

June 28, 2021

Programming, Tutorials

Run this AppleScript to Hear your Music in Glorious Mono

I often work while my son is sleeping or napping. My desk is right outside his room, so if I want to listen to music, I need to use headphones. But I'm also often the primary caregiver at the moment and need to keep one ear open so I can hear if he needs something, which means if I want to listen to music I need to use head*phone*.

December 8, 2020

Programming, Tutorials

Save 20 Minutes Every Time with this Complete NextJS Config

By the time you've finished this guide, you'll have a repo you can clone every time you start a new project. You can skip all that swearing and hair-pulling and get right down to coding.

October 27, 2020

Programming, Tutorials

Async Data-Fetching Sandbox

I recently needed to mock a very basic generic asynchronous data-fetching API with loading state in order to create a GitHub issue. I have a feeling it’ll be useful later, possibly even to other people, so here it is:

It uses a promisified wrapper around localStorage, with timeouts to simulate the async data-fetching, and local React state for loading, because my original use case for it was simulating a common pattern with the Apollo client. (But this should work for other kinds of async data-fetching.) It doesn’t really do much out of the box other than render a stringified version of the original data; even the data-update handler is commented out. Wire up however makes sense for you.

September 3, 2020

Programming, Tutorials

How to Patch an npm Package with `yarn patch`

One of the new features of yarn 2.0 is the ability to modify an installed package in-place, so you can incorporate your own changes or bugfixes without having to wait for the package maintainer to make those changes—or, indeed, so you can make changes you think the maintainer will not make at all.

September 2, 2020


Comments for Now You

There’s a programming joke about comments I heard a few years ago, kind of forgot, and can’t find now. It goes something like this:

Newbie Dev: Lol comments r dumb
Junior Dev: Comments explain what you did for other devs later
Mid-Level Dev: Comments explain why you did it for other devs later
Senior Dev: Comments explain why you did it for you later

I’ve always mentally added my own1:

Galaxy2 Dev: Comments explain what I’m doing right now

Not all that often, but sometimes, I’ll be banging my head against some intricate problem (it almost always seems to involve multiple JS Array.prototype.reduces for some reason), and eventually start to suspect that I’m mentally glossing over some aspect of the solution that isn’t making it into the code, or is poorly implemented, because I haven’t explicitly understood it to even be a problem. So I write a comment explaining to, ostensibly, a future me or future dev, but really to present me, explaining exactly what the program is intended to do. Then I write the implementation of the comment. This invariably gets me at least one step closer to the solution.

  1. I’m pretty sure this wasn’t in the original joke.
  2. I only just invented this classification for the purpose of this post.

August 26, 2020

A few bad apples spoil the barrel.

Stop letting people get away with saying “It’s just a few bad apples.” Challenge them. Or, at the very least, finish the saying in your head so you remain clear about what’s really happening.

June 7, 2020