Craig Mod on code as therapy

There’s healing power in those curly brackets and semicolons.

I’m slightly averse to JavaScript for reasons but I appreciate it’s one of the most popular programming languages around and a significant element of the Web. For Craig Mod, it is also a component of healing as he wrote for Wired:

Like many other writers and artists, I maintain a personal website. My current one has been active for nearly 20 years. Code in mind, I brushed off my rusty JavaScript skills and started to poke around for fuzzy-search libraries I could bolt onto my homepage, to make it easy to find specific essays from my collection.

Break the problem into pieces. Put them into a to-do app (I use and love Things). This is how a creative universe is made. Each day, I’d brush aside the general collapse of society that seemed to be happening outside of the frame of my life, and dive into search work, picking off a to-do. Covid was large; my to-do list was reasonable.

The real joy of this project wasn’t just in getting the search working but the refinement, the polish, the edge bits. Getting lost for hours in a world of my own construction. Even though I couldn’t control the looming pandemic, I could control this tiny cluster of bits.

The whole process was an escape, but an escape with forward momentum. Getting the keyboard navigation styled just right, shifting the moment the search payload was delivered, finding a balance of index size and search usefulness. And most important, keeping it all light, delightfully light. And then writing it up, making it a tiny “gist” on GitHub, sharing with the community. It’s like an alley-oop to others: Go ahead, now you use it on your website. Super fast, keyboard-optimized, client side Hugo search.

You had me at search, Craig (I’m an SEO). For me, coding in HTML, CSS, and Python—with the odd but of PHP tinkering on WordPress—has helped me through the pandemic and having my own online plot of land to maintain.

This part spoke to me too:

It’s not perfect, but it’s darn good enough.

The point being that a habit of reaching for code is not only healing for the self, but a trick to transmute a sense of dread into something: A function that seems to add, however trivially, a small bit of value to the greater whole in a troubling moment.

The world has been shit and you have a choice: wallow in it indefinitely or turn some of that negativity (and it’s realm relative, valid, and not to compare with anyone else’s) into something positive for each of us. Code is that playground for me and it seems to be the same for Craig.

(featured image credit: Christopher Hiller, shared via CC BY-NC-SA 2.0 licence)

Author: lukealexdavis

Luke Davis is a music producer and writer. In his spare time, he enjoys watching tennis, playing Pokémon, reading and admiring architecture.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.