4 ms·
It emphasizes separating logic from presentation: it is impossible to embed application logic in this template language. StringTemplate for C++ then. http://ww
by buff-a 15y ago
It emphasizes separating logic from presentation: it is impossible to embed application logic in this template language.
StringTemplate for C++ then. http://www.stringtemplate.org/ http://www.stringtemplate.org/
Its distinguishing characteristic is that it strictly enforces model-view separation unlike other engines. Strict separation makes websites and code generators more flexible and maintainable; it also provides an excellent defense against malicious template authors.
- judofyr 15y agoYou forgot the best part of StringTemplate: Terence Parr has even written a paper about it where he discusses some difficulties and solutions: http://www.cs.usfca.edu/~parrt/papers/mvc.templates.pdf http://www.cs.usfca.edu/~parrt/papers/mvc.templates.pdf
- SimHacker 15y agoFighting against malicious template authors is a losing battle I don't want to fight. I simply won't hire or work with somebody I consider malicious, and don't trust the general public to write templates for my system. Zope tried that with "safe python" and TAL/TALES/METAL, and it was an utter abortion.