Latest Articles - Programming



Teaser image

Pelican is a static site generator written in Python, which was used to create this site. Extending Pelican with plugins can be a powerful tool, but unfortunately when going to create my own first plugin, I found documentation to be somewhat lacking. So, I'd like to provide a few tutorials demonstrating how I built plugins for this site, starting with a very simple one.

This article assumes basic familiarity with Python, and working with Pelican to create a basic blog site, but does not assume knowledge of Pelican internals. Read more...


Teaser image

The Star Wars opening crawl has been replicated many times in HTML/CSS. It's almost a rite of passage for frontend web development students of a particular geekly persuasion. I threw my hat into that ring several years ago, and made an exacting reproduction of the Episode IV crawl (though never published it). I recently re-visited that project and decided to put an absurdist spin on it by turning the crawl into the most impractical weather report possible. Read more...


Teaser image

I ran across a quirk of CSS recently, related to the box model, that struck me as counter-intuitive behavior. To be honest, it's an issue I've repeatedly run into over the years that I've always bumbled my way around, and never fully understood.

Consider this simple example of a <div> element with a child <p> element that has top and bottom padding. Read more...


Teaser image

It hit me recently that I didn't understand something about how generator functions in Python work. In short, I was unsure exactly when and how they are determined by a Python implementation to be generators as opposed to "standard" functions, i.e. a function ending in return (whether explicit or falling off the end of the function).1 That question may not make very much sense at this point, but I'm not sure how to succintly word it without background information. To that end, there are three key facts about generator functions that led me to this question, described below. Read more...


Page 1 / 3 »