/ Development

Baking and development - two worlds not so far apart.

Web development and baking. At first glance, both could not be further apart, but that is just at a first glance. I will try to show you today why I became a better baker because of my development skills, and, if I dare, how my development skills improved when I became a baker.

A journey into the unknown

It was three years ago, late 2015, I was an operations director in a medium sized publicity agency. My wife, who had worked there until a few months prior, was struggling to find freelancing and had started, as a small side business, baking small cakes from home which she sold to close friends or did for her family.

A creature of the internet, she started posting her cakes on-line and slowly sales started picking up.  Close friends of friends, acquaintances  and eventually completely unknown people started requesting cakes. Demand started increasing.

That's when I finally stepped in to give a helping hand. At first she allowed me to mix ingredients, put cakes in the oven and clean the dishes, but slowly my participation started growing and I was permitted to decorate a cake here and there.

I could go on for hours here, but I'll put that in another post someday. Needless to say, I eventually dropped out of the agency and dedicated myself to the world of baking.

Baking, Ok - where is the programming stuff you promised?

Now I am a baker, like most of the stuff I have learned in my programming skills, I pretty much learned everything from watching youtube videos or reading on sites. One very different thing about learning to make a fully decorated cake with fondant and sugar flowers, and writing a ToDo app in VueJS is; a VueJS ToDo App will pretty much always work if you follow the tutorial, the cake... not so much.

Anything you can imagine with a cake can go wrong. There are so many variables to take into account. Ingredients, proportions, temperature, weather, and time are just some of the ones that come to mind, yet, if we make a parallel with our ToDo App, we have variables such as Version of Vue, OS, Node Version, and Database.

With a little bit of trial and error, I eventually got the logics of baking cakes. Very much like development Design Patterns, cakes have their own Design Patterns.
Replacements can be made, ingredients can be added, subtracted, you can tweak things here and there. If you learn the basic rules of baking or Logic of baking, you can apply them to pretty much any recipe.

Once you've done your ToDo app a couple of times, you feel pretty confident about your skills, and decide to venture off on your own and create a "New and improved ToDo App" with all the bells and whistles. Just like baking, if you are not aware of the pitfalls, if you are not following a set of guidelines or rules, you'll probably end up with a great big pile of junk. (The advantage of development though, is that you haven't really spent any ingredients like you do in baking).

Patterns and logic

From developer to baker - As mentioned above, when you are a developer, you are trained to identify patterns, trained to use logic to solve real life problems. These skills prove to be of extreme value to something like cooking.  Finding the patterns in baking is no different than finding the patterns in a code. Every time you do a recipe, it's like refactoring a piece of code you've written. You find a process you can do better, or something that has to be done a certain way to work properly every time.

Form baker to developer - Baking is something that has little room for errors. From my mistakes, as little as 20% more or less of an ingredient is enough to completely wreck a cake. 5 minutes in the oven is enough to turn your red velvet cake into a brown and red-stained mess of sadness. Process is the key to everything in baking. Plan what you are going to do, setup for doing it, separate ingredients, validate that you have the right amount of everything, if possible, lay them out in the correct order, double check everything beforehand, then, execute a step, check it off, and repeat this until you've done everything you had to. This process can become incredibly long when you are talking about a three tier cake, with three different filling, a rainbow coloured batter, sugar flowers and lace piping.

This iterative process, does not stray too far from the process I now develop my code. I plan a feature - have an idea of what my tests should look like, setup my git branch, start my development process, interact, check, commit and repeat. Like with my cakes, at any given moment, a team member could step in, take over the process, and continue work without a hitch.

A vision of how things fit

Knowing how things all fit together is essential on both jobs. If you are not clear about how each process fits along with other processes, or how each individual feature will interact with another feature, you are likely to end up with a mess, be it a cake or code. Having a clear vision of the final product is imperative.
At the bakery, we often draw out what the cake should look like. We separate out the parts that require more attention, sometimes we will even create mock versions of the cake with paper representations of flowers or fondant dogs so that we understand sizes, shapes and formats.
With code, the same applies. Rather than a picture (in the agency we used wireframes), I now prefer to write down what I expect the project to be. I go breaking it down until I have a series of tests I can write to test my code.

Respect timing

In baking, time is one of the key factors. Time to cool, time to reach room temperature, time to bake, time to set, time to proof, and so on... these are all parts of the process of baking. Try adding some buttercream to a warm cupcake? If you've watched "Nailed It" you most probably know what I am talking about. Hot cake with room temperature butter spells disaster. There is no miracle. You can speed tings up a bit, but, inevitably, you must respect time.

In programming,  the same rules apply. A feature takes time to implement. Testing takes time, programming takes time, refactoring takes time. You can take shortcuts here and there, but if you eat up too much of your time, you'll either deliver a buttery mess of a code, or you'll not deliver something your client wants.

Breaking it down

Making a wedding cake is a very labor intensive process. It requires planning and sometimes thousands of moving parts. Creating a full featured single page app is no different. Migrations, models, controllers, helpers, events, apis are all layers of cakes and fillings that make the base for something great. That alone should impress anybody, but just like a fantastic basic cake, perfectly stacked, will impress pretty much only other bakers, the same applies to you perfect stack of layers in an app. Developers can be impressed, but very few users will understand all that has gone into it. It's the perfectly smooth fondant with crisp edges, it's the hundreds of strands of royal icing creating intricate lacing, it's the thousands of perfectly assembled, and individually made rose petals forming realistic roses and rose buds, it's the leafing and the perfectly hidden floral wire that structures the cake that users look at with their jaws dropped in amazement. Just like the hundreds of components your app has, that little date picker, the slider that snaps, the little hover effect your button has to denote it is interactive. Each little tiny detail must be tailored to a very specific need and desired outcome.

So at the end of the day

My development knowledge has helped me learn baking to a completely new level, I have already received compliments from a Michelin Star Chef for some of my recipes and I've even won a TV show to the liking of "battle of cupcakes" with my infamous lemon, vanilla cream cheese cup cake.

Baking has made me a more careful programmer. I have become more process oriented, better organised, more patient and in general more efficient. I've replaced a good part of my trial and error with smaller iterations, I document stuff more often than not and very seldom leave something half way finished. I make sure my planning takes into account the time things take to build or process.

Baking has made me a better coder, and coding has made me a better baker. Now all that remains is to see which of the two will make me infamously rich!

Gregory Brown

Gregory Brown

Baker, cake designer, cook and just by chance, a full featured developer that is passionate about technology.

Read More