Stuff I wrote

A range of unique and possibly interesting web development ideas of varying quality. Basically "I think stuff and sometimes I write it down".

Using CSS variables correctly

CSS Variables (also known as Custom Properties) are now supported in all modern browsers and people are starting to use them in production. This is great but they’re different from variables in preprocessors and I’ve already seen some examples of people using them without considering the advantage they offer. They have the potential to change how we write and think about CSS. I thought I’d do a few quick demos that show some good and bad ways to use CSS variables, and how their differences from preprocessors might change how we structure CSS.

Continue reading

Non-linear interpolation in CSS

A few years ago I wrote about fluid typography techniques that show how you can use calc() and viewport units to create transitions between different font-sizes as the viewport size changes. If you’d like to know more about how this technique works you should read my article Precise control over responsive typography. Recently these ideas have circulated and gained more traction. I’ve seen more large sites using fluid typography and other people writing about it and expanding on my initial ideas and techniques.

Continue reading

The invisible parts of CSS

If you use CSS in your daily work, your primary goal is probably focused around making things ‘look right’. How this is achieved is often far less important than the end result. This means we care less about how CSS works than the correct syntax and visual results.

Continue reading

Interpolation in CSS without animation

Interpolation is the estimation of a new value between two known values. This simple concept is vastly useful and it’s commonly seen in animation on the web. With animation you declare the target properties and the end-state, and the browser will workout out the values in-between. Animation happens over time, but this is not the only dimension where interpolation can occur. In fact we interpolate values regularly in design, albeit manually, and particularly in responsive design. You may even do it unknowingly. Because of this, I think there is a need for a more native way of interpolating CSS values outside animation.

Continue reading

VR Pong

I published a new project today named VR Pong. It’s a collaboration where Una Kravets and I learn about WebVR and hopefully make something cool. The idea is that each week one of us adds something to a VR scene then passes it back for the other person to build upon. We’ll also write a short blog post about what we learnt both creative and technical. So far we added one ‘Pong’ each.

Continue reading