Articles

November 07, 2019

Designing a running training plan

I like to run. I run a lot, and I've found myself running every day of the week with little focus on what I want to achieve. Every day is the same 4-8km with a longer run on a Sunday. It's quite hard to progress myself, and measure my progress when I've been doing this because it all stays the same. Monday - Run 4km because my legs are tired Tuesday - Run 6-8km Wednesday - Run 6-8km Thursday…

Keep Reading →

February 15, 2019

Theming Slack using a message

The Slack (desktop) client allows you to create your own themes. But did you know that you can also set the theme via a message. Simply send a message with the contents being 8 comma separated hex codes. You don't have to send the message to anybody either - Just send it to yourself! These stand for the following elements: Sidebar & top bar background ???? Highlighted channel background…

Keep Reading →

October 06, 2018

Getting to grips with CSS Grids

Grids are the latest layout model to join the CSS spec after flex. Like flex, grids open up a whole new world of layout possibilities that will make every web developer's life a whole lot easier. Unlike flex, grids allow you to use more than one dimension at a time. Flex is row OR column. Grid is row AND column. As with flex there are some issues with support, but CSS Grids works on the latest…

Keep Reading →

April 11, 2017

Create a basic ReactJS app with no config

There are many ways that a ReactJs app can be created. The aim of this guide is to get up and running with a basic react app as quickly as possible. That means no other fancy libraries such as Redux, Router, Relay or anything else beginning with R (seems like there is a theme going on). There’s also going to be no Flux or jQuery or any other async included and certainly no configuration needed via…

Keep Reading →

July 18, 2016

Hide number input spinners using CSS

HTML 5 number pickers are great, since they help restrict users to the input ranges required in certain cases. Some browsers add little up and down arrows to help the user step though numbers. On some browsers the pickers show by default even when the form inputs are not focused, which is a bit ugly. You can use CSS to turn off the number input arrows. Obviously you want to put them back on…

Keep Reading →

July 12, 2016

Running a simple server while developing locally

When you’re building a website one of the most important steps is the building of the templates. Building static templates is almost always quicker than building integrated templates such as WordPress, Django or Rails. One of the biggest issues with using static templates straight off the file system is that file:// urls can have issues and relative links may have to be different than what they…

Keep Reading →

July 10, 2016

Javascript best practices

Where to put the javascript? Unless it’s essential for it to be in the head of the HTML document, place all javascript just before the closing body tag of a page. What’s essential for the head? That can vary from project to project but a rule of thumb would be: A minimal amount of inlined javascript Any javascript that can be loaded async. What should do in the footer jQuery. Nothing essential…

Keep Reading →

June 14, 2016

A Project code guideline

This is my documentation for a new project. I’m writing it here rather than inside a repository so that it can exist across multiple projects. This will eventually be duplicated on to a markdown document for posterity! Project structure As the project is Django based, the front end files (CSS, Javascript and Media) can live in a few places — The Project folder, the static folder and every app’s…

Keep Reading →

February 19, 2016

Lessons learnt from my first iOS Game

A few weeks ago I decided to make an iOS game. I’ve toyed with the idea for a long time, and tried a few times, but never actually made something that was fun enough and worked properly — consequently, I’ve never actually made a game from start to finish. Previously I only got so far, then got stuck, got disheartened and gave up. This time it’s different… What did I want to achieve? Make a fun…

Keep Reading →

February 09, 2016

Start using Git

Turning any project in to a Version controlled project is really simple and should be one of the first steps in any project workflow. By the time you realise that you need a version controlled file, it’s usually too late – whether you have accidentally overwritten a days worth of work on a file, or you deleted the wrong thing. Since it’s so easy to setup, there’s really no excuse not to. There are…

Keep Reading →

December 16, 2015

CSS best practices

There are a few ways of writing css. For consistency we will adopt only one naming convention. This is lowercase and hyphen separated. It is the most readable and fits well with other CSS methodologies that are covered below. Yes No Specificity Keep your selectors short and with as low a specificity as possible. A maximum of three classes in your selectors is recommended. Why? Two reasons…

Keep Reading →

May 02, 2015

WordPress localhost redirects to live site

When you are developing on WordPress sites it's always quicker to work on a local machine/development server. It's essential to work from the same data as the live site so you can work effectively as possible so taking a copy of the live database and installing it locally is the best and quickest option... but there is one potential pitfall. Because WordPress store site settings in the database…

Keep Reading →