03: Rule Sets

Now I start to show you the most basic element of CSS and how it interacts with the HTML Document Object Model (DOM). When we talked about the DOM in the HTML module I showed you how the HTML tags are structured into a tree, with parents and children. The problem with trees is they're difficult to process without some kind of "rules engine". A rules engine is a way to specify what should happen when certain things are encountered in a tree. You give the browser a set of rules, the browser "walks" the DOM, and if any part of the DOM matches your rule, then the browser runs it.

Your Files Are a Tree

A simpler way to explain trees is to use what you know about the command line from the First Steps module. If you remember you can use a command like this:

cd Projects/ljsthw/ex1

80% Discount for Alpha 1

Register today for the early access release and get an 80% discount on the final release price. You'll get true lessons in true modules right now, and early access to content as it's released.


Still Not Sure? Check out more curriculum!