Tue 11 Dec 2018

BalenaEtcher external

Usually I would use dd to write images to SD cards but I always worry I will mess it up. Today I used BalenaEtcher and it was dead simple and worked really well.

Tue 06 Nov 2018

Werner’s Nomenclature of Colours external

"A recreation of the original 1821 color guidebook with new cross references, photographic examples, and posters designed by Nicholas Rougeux" Quite simply a beautiful website.

Wed 24 Oct 2018

A Question of Timing external

I saw this blog from Cloudflare via a tweet from Ilya Grigorik. It explains how to see timings (dns lookup etc) for every curl request.

Thu 27 Sep 2018

Mon 24 Sep 2018

Whenever I use sqlite in Node I always come across the issue where the database hasn't been created properly. This is the code I've been using to ensure it does.

const dbpath = 'database.db'
const dbPromise = Promise.resolve()
 .then(() => new Promise(function (resolve, reject) {
 // Make sure database exists before trying to open it
 fs.writeFile(dbpath, '', { flag: 'a+' }, function (err) {
 if (err) reject(err)
 else resolve()
 })
 }))
 .then(() => sqlite.open(dbpath, { Promise }))
 .then(db => db.migrate({ migrationsPath: 'migrations/' }))

Sat 22 Sep 2018

Designing A Textbox, Unabridged external

I wrote this article for Smashing Magazine as a way to explore how complicated the most seemingly simple of tasks can be. In it I create a textbox but go through a very exaggerated process of defining exactly how it should work.

Thu 12 Jul 2018

Fri 06 Jul 2018