Am 22.09.2012 01:09, schrieb Eldar Insafutdinov:

For some specific reasons I wanted not to escape the template
parameters. I was about to modify diet to provide an option of not doing
it, before I came up with quite an elegant trick. Because Diet calls
htmlEscape function to do escaping I realised that I could pass my own
symbol with the same name to override the default behavior:

auto htmlEscape = (string a) { return a; };
res.render!("signup.dt", htmlEscape, data);



Interesting idea ;)

Btw., it's not yet documented, but you can now also use !{} on master to
make unescaped string interpolations and attributes and element text are
not getting escaped anymore - the former behavior didn't really make
sense and actually double-escaped attributes.