Proton is a simple, "code-less" engine for xml/xhtml templates. Code-less, because it uses 3 types of ID (attribute) in a template file, rather than snippets of code — this moves the complexity out
... [More]
of the template and into the application.
There are currently implementations available in Python (Py3K) and Java.
A simple Proton template looks like this:
PAGE TITLE
PAGE TITLE
LINK ITEM
LIST ITEMS
And to render this template, you might do something like this:
tmp = Templates()['test.xhtml']
tmp.setelement('title', 'An Xhtml Page', '*')
tmp.setelement('link', 'This is a link to Google')
tmp.setattribute('link', 'href', 'http://www.google.com')
tmp.repeat('list-item', 5)
for x in range(0, 5):
tmp.setelement('list-item', 'test%s' % x, x)
print(str(tmp)) [Less]