Thoughts on recipes and Cooklang

Note: I originally wrote this a few months ago, and it’s been sitting in my drafts folder ever since. Chunks of it are no longer accurate — I think I’m going to end up rolling my own 11ty plugin, for example — but it mostly represents where my thoughts have settled, and so I might as well publish it…

Not quite five years ago, in the midst of the initial phases of the pandmy, I sat down and banged out some thoughts about recipe affordances. I’m still thinking about some of these things, particularly as I ponder converting the backing store for recipes.genehack.org over to something like Cooklang.

First, a quick review of the points from the recipe affordances post, with brief thoughts on whether I still agree with Past Me:

  • I still think recipes are better laid out as equipment, materials, and instructions, and that instructions are better split (most of the time, anyway) between “prep” and “cook” phases.

  • I also still think it would be better if recipes made it clear, for the prep phase, which ingredients were going to end up getting used at the same during the cooking phase, so they can be prepped into common containers.

  • After reflection, I don’t think there’s a lot of utility into annotating ingredients as “staples” versus “need to buy” — too much variability from kitchen to kitchen as too what counts as a “staple”, and it’s pretty trivial to prune the ingredients list into a shopping list.

  • Ditto for the breakdown between required and optional equipment; I think if there is a need for something optional, that can be handled in the recipe steps, it doesn’t need to be part of the recipe layout.

So far, if you’re at all familiar with Cooklang, you’re probably thinking that there’s a pretty good match up — Cooklang lets you annotate ingredients and equipment, and it lets you (but doesn’t require you to) denote distinct phases or sections of recipes.

There’s also an 11ty plugin, which would make using it with the existing recipe site structure pretty easy …so, really, what’s not to love?

Unfortunately, my initial explorations around actually using Cooklang quickly ran into a parsing bug, which the maintainer seems uninterested in fixing due to long-term plans to go in a different direction — which is fine, but took some of the wind out of my sails, for sure.

So now I’m pondering whether I want to spin up my own parser …and to be honest, that feels like maybe not that bad? There are a few things about Cooklang that I’d like to work a little differently — dealing with divided ingredients, for one — and there are other aspects that I’m sure I’m never going to use, like shopping list generation, which I could just …not implement. I’d probably need to tweak the 11ty plugin, to allow the parser to be overridden — but that also feels pretty doable.

So, new hobby project, maybe? …maybe.