In a private project of mine I recently had a grid layout (props to Harry Roberts’ csswizardry-grids, which I love). This grid contained links for a user to navigate, but users with few privileges could only see a few of those links, and I didn’t want them to see a three-column grid with only two elements. So I started searching for ways to combine the
:nth-child selectors to solve this issue.
Continue reading Selector Counting
Good brownies are surprisingly hard to come by. Supermarkets will sell you slices of dry chocolate cake as “brownies”, cafés tend to have homebaked slices which are always nice but never quite chocolatey enough. I’ve been trying to find a recipe for a real, honest, chocolate brownie.
Continue reading Recipe: Brownie Muffins
When you first start learning specificity, you’re introduced to concepts such as tag selectors, class selectors (dot-prefix) and ID selectors (hash-prefix). You then start writing rules, selecting things left and right — and at some point hit a wall when suddenly a selector doesn’t work.
This is usually due to specificity, the rules that determine which selectors have higher priority.
Continue reading Specificity, or Why doesn’t this bloody selector work?
This is the first post in a series on CSS basics. I will be attempting to convey basic concepts that I felt were instrumental in my understanding of CSS, in the hope that it will aid someone learning CSS in their understanding of the syntax and its uses.
Let’s start at the very beginning, the style imports. This article will cover where the browser loads stylesheets from, which might clear up some confusion when you inspect an element and discover e.g. a
margin declaration that you’re sure wasn’t declared anywhere!
Continue reading Where does my CSS come from?
This is my brand new blog, where I am intending to have a mix of code-related posts and notes on cooking I did. If you’ve managed to find this blog early in its life, please excuse if it’s a little rough around the edges; I’ll be focusing on content first, then polish 🙂
Relevant XKCD, don’t want to leave you hanging…