CSS Tutorials

  • By
    Getting Dicey With Flexbox

    What if you could build complex CSS layouts in minutes? Flexbox is a new CSS layout spec that makes it easy to construct dynamic layouts. With flexbox, vertical centering, same-height columns, reordering, and direction agnosticism are a piece of cake. There's a popular myth floating around that...

  • By
    Reducing Memory Leaks when Working with Animations

    I have been doing a lot of work with Snap.svg recently and you may have already seen an article a while back regarding SVG animations. After the article had been published, I took some time out to review the code I had written and found that...

  • By
    Web Animation using JavaScript:  Animating Text
  • By
    Sara Soueidan’s Favorite CodePen Demos

    A few months ago, Chris Coyier shared his favorite CodePen demos right here on David's blog. A while back David asked me to share some of my favorite pens too, so here are some of the demos that have blown my mind in the past...

  • By
    Ana Tudor’s Favorite CodePen Demos

    Cocoon I love canvas, I love interactive demos and I don't think I have ever been more impressed by somebody's work than when I discovered what Tiffany Rayside has created on CodePen. So I had to start off with one of her interactive canvas pens, even though...

  • By
    SVG Animations Using CSS and Snap.svg

    Today I wanted to share with you the ease of animation in SVG with the tools we have available to us today. SVG is still one of those subjects that can scare away a lot of developers, but I'm here to show you hopefully just...

  • By
    Regular Expressions for the Rest of Us

    Sooner or later you'll run across a regular expression. With their cryptic syntax, confusing documentation and massive learning curve, most developers settle for copying and pasting them from StackOverflow and hoping they work. But what if you could decode regular expressions and harness their power? In...

  • By
    Font Smoothing in Webkit and Firefox

    I don't pretend to be a typography or design expert -- I just know what looks good and what doesn't.  A few years ago I saw a few CSS properties I didn't recognize and when I toggled them on and off, the text went from beautiful to...not...

  • By
    Scoping CSS Animations to Media Queries

    When coding my blog's redesigns, I think and design the site in device width stages, and in the following order: Desktop:  all general styles, none wrapped in a media query Tablet:  media query, roughly popular tablet widths Phone:  media query, any width below tablet width Print:  media query, mostly a bunch display: none Since I focus on...

  • By
    5 Ways to Make Your Site Smaller and Faster

    Confession:  I'd say once a week I genuinely wish I was a kid who spent his work day cutting grass and doing landscaping.  Why?  Because at the end of the day, they are able to say "the grass is cut, the job is complete."  As Web Developers, we...