Faster, Easier, Safer HTML

Existing web template engines and static site generators are insecure, weak, and slow – so I had to write my own.

Consistent Syntax

It is easy to read and a pleasure to write. Markup closely resembles the resulting DOM tree.

(p (q "Hello World"))
<p><q>Hello World</q></p>

Idiosyncracies of HTML, such as the arbitrary distinction between elements and attributes, are automatically made sensible.

(iframe (srcdoc (html (lang "en") (head) (body "Howdy"))))
<iframe srcdoc='&#x3C;!DOCTYPE html&#x3E;&#x3C;html lang=en&#x3E;Howdy'></iframe>

Mandatory Validation

Elements and attributes are checked for conformance with the HTML standard, meaning every generated document is guaranteed to be valid.

(fieldset (button "compute") (legend "calculation"))
HTML-ERROR :LEGEND must be the first child of :FIELDSET

There is never any need to allow unsafe or unescaped text. All content is appropriately and correctly sanitized.

(a (href (mu:url :path ("." "©") :query (q "/"))) "#")
<a href='./%C2%A9?Q=%2F'>#</a>

Flexible Templates

Custom user-defined templates reduce repetition and increase productivity.

The system is versatile enough to function as a static site generator, or to produce markup on-demand as a dynamic website’s templating engine.

  :title "Home"
  :heading '(~ (:lang "fr") "Bienvenue")
  :content `(:p "It is now " ,(iso-8601 (now))))))

Blazing Performance

Templates are compiled to efficient machine code for unparalleled speed.

My entire website can be compiled in less time than other systems take to generate a single page.

$ find htdocs/ -name '*.html' -delete ; ./
Evaluation took:
  0.025 seconds of real time
  0.030000 seconds of total run time (0.030000 user, 0.000000 system)
  120.00% CPU
  22 lambdas converted
  87,420,364 processor cycles
  4,998,736 bytes consed