Rafael
November 2, 2021, 3:43am
1
I know I can create a list of the Tiddlers connected by their tags with the following syntax:
<div class="tc-table-of-contents">
<<toc "Root Tag">>
</div>
However, I’d like to substitute Root Tag by the title of my Tiddler. So I’ve tried:
<div class="tc-table-of-contents">
<<toc "{{!!title}}">>
</div>
It doesn’t work though, what am I missing? Why the {{!!title}} variable is not catching the value of the title of my Tiddler in this context?
Mark_S
November 2, 2021, 4:02am
2
You can’t substitute text that way into a the macro wikitext (meaning the << ... >> nomenclature.) There’s more than one way around this, but the easiest is probably use the macrocall widget instead:
<div class="tc-table-of-contents">
<$macrocall $name="toc" tag=<<currentTiddler>> />
</div>
pmario
November 2, 2021, 7:49pm
3
This works too:
<div class="tc-table-of-contents">
<$macrocall $name="toc" tag={{!!title}}>>
</div>