viktor-ferenczi / genshi-compiler

Genshi markup template compiler
0 stars 0 forks source link

Add support for mixed use of attribute and item lookups on template variables #10

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
We should add support for both the regular attribute and item lookup methods of 
accessing variable contents in template expressions as described here:

http://genshi.edgewall.org/wiki/Documentation/templates.html#template-expression
s-and-code-blocks

It should be optional, since supporting this laziness will require additional 
code executed at template rendering time, which will slow down rendering for 
sure.

I think it is generally bad practice to look up attributes as items and 
vice-versa, since doing so would effectively obfuscate the type of objects. So 
I would not enable this compatibility feature by default.

Original issue reported on code.google.com by ferenczi.viktor on 5 Aug 2011 at 3:34

GoogleCodeExporter commented 9 years ago

Original comment by ferenczi.viktor on 16 Jan 2012 at 3:10