3 ms·
A while back, I wrote a very small Python HTML rendering library that gives some of the benefits of this notation while still being Python source code. You _may
by oofoe 16y ago
A while back, I wrote a very small Python HTML rendering library that gives some of the benefits of this notation while still being Python source code. You _may_ find it interesting if this is the sort of thing you find interesting...
http://hotwax.cjmunday.com/python.html#sec-1.2 http://hotwax.cjmunday.com/python.html#sec-1.2
See the CherryPy file browser example later in the page for a demonstration of how it's used.
- true_religion 16y agoOh definitely. To me, it seems that everyone is striving to find an easier way to programmatically create HTML in Python. The current range of templating languages just don't cut it. I think there's no definitive solution partially because everyone is copying Haml, and Hamls' syntax and trade-offs aren't really appropriate for Python users.