Blog

Adding an RSS feed in Keystone.js

I recently rebuilt my personal website on KeystoneJS and immediately fell in love with it. I think it's for the following reason: Keystone has successfully married NoSQL with the basic concept of the CMS.

Read more >>


Three mundane things you can do with recursion

I have been spending some quality time with Clojure, not because I think I'm likely to use it for a real project any time soon, but because both the syntax and behaviour of the language are so different from what I'm used to that I feel like a total n00b again. This is uncomfortable, but it's a good thing: I'm looking at my even my production code in a whole new way.

Read more >>


DIY Lazy Load

I am constantly looking for practical ways to get all the beautiful images in a design to load without hampering the page load unreasonably.

Read more >>


How to keep your promises: JavaScript edition

The first time I needed to access a third-party API on the web I remember doing something like the following (in PHP):

$data = file_get_contents('http://a/resource/somewhere');

This has the advantage of being really easy to read: like all other parts of my code, I assign a variable to an expression and expect that it will be filled with a value of some sort. What I never thought about at the time was how much was going on behind the scenes: unlike an basic expression that performs a math operation or comparison, a whole HTTP request and response is going on before $data can be filled. During this time, my program pauses and no further code is executed.

Read more >>


In the beginning was the code, and the code gave life, and the code was life

The oldest gene we possess carries the information to make something called the 5S RNA, a component of the ribosome. This molecular machine is responsible for translating a DNA sequence into a protein sequence. The reason this is critical is that chemical properties of DNA are pretty simple: it's more or less just a carrier for information. Proteins on the other hand, have astoundingly complex chemistry: they can synthesize or break down sugar, create pigments to give us a specific hair colour, give us or prevent cancer. In short: everything.

Read more >>


Journals: Your domain is now your reputation. Protect it.

One facet of web sites that often confuses clients who have not been involved with the web before is that they have to pay separately for their domain and their hosting. While the different bills can be annoying and seem like a scam, there is very good reason to keep them distinct and one should actually be wary of any "package deals" that sell both at once.

Read more >>