TO DO - Uize.Template
- 1. Active Widget Templates
- 2. Look Into Supporting Subclassing
- 3. - other encodings to support
- 4. - for templates...
This is a TO DO document for the
1. Active Widget Templates
<div class="<%@ nodeClass('thumbnail') %>"></div>
<div class="<%. nodeClass('thumbnail') %>"></div>
<div id="<%. nodeId('thumbnail') %>"></div>
<div> <%| firstName, lastName | firstName + ' ' lastName %> <%. firstName %> </div>
from string replacement, how does one determine dynamic updaters?
process template, where all assignment expressions are enumerated, replaced with simple assignments, and where each enumerated assignment is provided with a unique value that is safe for substitution in attribute values or text nodes, unique enough as to be discoverable with a simple text search
|the dummy template is processed with the dummy inputs|
|the generated DOM is scanned and attribute values and text nodes are scanned for the unique dummy inputs|
|based upon where the dummy inputs are discovered, dynamic updaters are generated, with a maximum of one updater per attribute value or text node|
|if multiple dummy inputs are found in the same attribute value or text node, then the entire value for the attribute value or text node will be recalculated|
2. Look Into Supporting Subclassing
Subclassing of templates would allow template subclasses to more easily use the rendering features of their base classes.
Also, any features defined in a template base class and that are used for rendering can then be accessed of public instance methods from the subclass. Perhaps a separate question is how .jst files that can be compiled into template modules can expose generator functions as methods, to be used by external code. Would the
input directive then define the properties for the class?
3. - other encodings to support
trim (Uize.String.trim or Uize.String.Lines.trim?)
trimLeft (Uize.String.trimLeft or Uize.String.Lines.trimLeft?)
trimRight (Uize.String.trimRight or Uize.String.Lines.trimRight?)
4. - for templates...
|multi return value templates (blocks that can assign output to specific output property)|
|support whitespace gobbling|