Files
sdk/utils/tests/template/callview.tmpl
T
terry@google.com cea0d08c1d Template bug fixes and new features.
Fixed textnode bug, whitespace was being removed. Added added local name for #with and #each.  Form of ${#each list [localName]} and ${#with object [localNme]} Added ability to call another template (located in the same tmpl file).  Form is ${#templateName(parms)}

BUG=
TEST=

Review URL: https://chromiumcodereview.appspot.com//9728009

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@5665 260f80e4-7a28-3924-810f-c04153c831b5
2012-03-19 23:12:37 +00:00

19 lines
432 B
Cheetah

template NameEntry(String name, int age) {
<div var=topDiv attr="test" attr1=test1 attr2='test2' attr3=test3>
<span var=spanElem>${name}</span>
<span> - </span>
<span>${age}</span>
${#NameEntry2(name, age)}
</div>
}
template NameEntry2(String name, int age) {
<div var=topDiv2 style="background-color: yellow;">
<span var=spanElem2>${name}</span>
<span> - </span>
<span>${age}</span>
</div>
}