Folks,
I was looking through tiddlywiki to find how it does things because if you are left on a desert island or isolated with corona virus and no internet, tiddlywiki is in some ways its own documentation. I came across this in the tiddler $:/core/templates/exporters/TidFile which piqued my interest.
\define renderContent()
{{{ $(exportFilter)$ +[limit[1]] ||$:/core/templates/tid-tiddler}}}
\end
\import [[$:/core/ui/PageMacros]] [all[shadows+tiddlers]tag[$:/tags/Macro]!has[draft.of]]
<<renderContent>>
Already I often use the triple curly braces to get a quick filter result
{{{ [all[]prefix[New Tiddler]] }}}
Observe how the triple curly braces not only evaluates a filter but then displays the result via a template?
{{{ [all[]prefix[New Tiddler]]||$:/core/ui/ListItemTemplate}}}
For example the above uses the existing list item template to render the list resulting from the filter, but it is no different to the default
$:/core/ui/ListItemTemplate
<div class="tc-menu-list-item">
<$link to={{!!title}}>
<$view field="title"/>
</$link>
</div>
You can see how this template is quite simple;;
And lets edit it to include the description
Tiddlername Description
<div class="tc-menu-list-item">
<$link to={{!!title}}>
<$view field="title"/>: {{!!description}}
</$link>
</div>
Now you can use
{{{ [all[]prefix[New Tiddler]]||Description}}}
To list everything in the filter and its description if it exists.
Or make the template DescriptionRow
<tr><td><$link/></td><td>{{!!description}}</td></tr>
And use
<table>
<tr><th>Name</th><th>Description</th></tr>
{{{ [all[]prefix[New Tiddler]] ||DescriptionRow}}}
</table>
The possibilities abound.
have fun
Regards
Tony