Blog (page 14)

SSH Passphrases in MacOS Sierra (and learning Vim)

Managing SSH keys for remote repositories ain’t easy to grok. “Multiple Accounts and SSH Keys” is to no suprise one of my most popular articles. It’s still relevant and I have to refer to it myself at least once a year. Recently MacOS began requesting my passphrase with every Git push and pull. That is not productive. The solution is two […]

TypeScript over React PropTypes

React v15.5.0 is here and the React.PropTypes module gives a deprecation warning. Moving forward you’ll find it in it’s own package. I’ve always used React PropTypes because it seemed like the ‘right way’ to do things. Runtime validation has obvious value but in my experience there are three big negatives to it: PropTypes are tedious to write PropTypes […]

The Magic of Service Workers

They’re a thing. Google describes them as a “technical foundation”. What I’ve learnt is that a service worker is a JavaScript file. It runs in it’s own little world behind a website. That means it can’t access the DOM. What it can do is proxy network requests and access a storage cache. I’m sure they can do […]

I watched Iron Fist and coded CSS 👈

They have nothing in common. Well, aside from entertaining my weekend. I’m just bad at blog titles and I’m fed up of writing nonsense like “CSS modularity; theory and practice”. My draft title, which let’s face it, nobody is clicking. Iron Fist is ‘aight I guess. I’m 7 episodes deep and I’m still awake which is an […]

Web Security and Cloudflare

I’ve never had to deal with SSL certificates before. That’s always been someone else’s responsibility. Being ignorant of the technical details, the idea of setting up SSL/TLS wrong scares me. The idea of my visitors seeing those browser warnings scares me even more. And they’re getting scarier by the year. I listened to an episode of […]

React as a Static Site Generator

Two years ago I converted my website from WordPress to a static build process. It has served me well but the final process was rather messy. Hacks and plumbing to get Metalsmith plugins working my way didn’t helped. Time for a new project! Abstract: rebuild my website using React as the template engine for a bespoke static […]

Working with Promises

JavaScript promises are a handy way to write asynchronous code. It’s common to have multiple promises resolve in parallel or series. Let’s say you have several functions that return a promise: It’s easy to run these functions in parallel: But how to run them sequentially? One way is to nest the promises: Nesting gets uglify real fast and some […]

Buy me a coffee! Support me on Ko-fi