1. Shu Zong Chen
  2. zanderloo


Clone wiki

zanderloo / Home


Welcome to Zanderloo, the pure Python DSL for CSS. Zanderloo is a (distant) fork of Zoolander, redoing the core markup, adding all new functionality and features.

Why use Zanderloo?

  • Write CSS using python - take advantage of variables, logic, loops, mixins, and other programmable neatness missing in CSS.
  • Nest your styles - all child node selectors are crossed with all parent selectors if you .extend() a rule.

What does it look like?

from zanderloo import *
sheet = Stylesheet()

    css("body", "table",
        font_face = "Helvetica, sans-serif",
        ("h1", "h2"),
        font_size = em(0.5),
        font_weight = bold,

print sheet.render()


  • Combiner to merge mutliple stylesheets together.
  • More flexibility in defining rules with multiple elements (e.g. margin = (px(0), px(0), px(0), px(0)) )
  • Fancy methods for color manipulation (Hex().darken() or Hex().reverse() or whatever)