Although I haven’t written proper documentation for it, the TiddlyTools TOC macros are suitable for general use.
Just import https://tiddlytools.com/#TiddlyTools%2FTOC into your TiddlyWiki (via drag-and-drop). You can then use
<<toc-tree roottagname>>
to display a TOC that is very similar to the TWCore <<toc-selective-expandable roottagname>>, some very useful added features:
- As @etardiff noted, TiddlyTools
<<toc-tree>>includes handling for auto-opening branches that contain the current tiddler (as defined by the$:/HistoryList!!current-tiddlerfield contents). - TiddlyTools
<<toc-tree>>also has handling for drag-and-drop re-organization of the tree items. Drag any tree item (or linked title in tiddler content) and drop it onto an existing tree item and it will be automatically inserted as a “child” of the tree item it was dropped on. If you hold the CTRL key when dropping, the dropped item will be added as a “sibling” BEFORE the item dropped upon. If you hold the SHIFT key when dropping, the dropped item will be added as a sibling AFTER the item dropped upon. - The
<<toc-all>>macro shows the entire tree without the “selective expandable” handling - The
<<toc-list>>macro outputs the entire tree as a “flat list” of tiddler titles. You can then use
<$wikify name="tids" text="<<toc-list roottagname>>">
to capture this list for further processing (see InsideTiddlyWiki TiddlyTools/NavBar/Bottom for an example of previous/next navigation links)
enjoy,
-e