If there is a plugin or a macro that can already do what I’m trying to do here with Tidgraph, please let me know!
Just recently, I’ve setup BASIC Anywhere Machine with an include directive.
(i.e. the ability for a BASIC program to transclude BASIC code from another tiddler.)
I’ve since been thinking about how to set something up to eliminate the possibility of unintentionally transcluding the same tiddler more than once (say two tiddlers being included into my BASIC program each transclude a common tiddler.)
Not a problem that would normally matter in TiddlyWiki (content duplication), but it is the kind of thing that will cause an error in a BASIC program if, say, a same function/subroutine/variable/constant is duplicated.
As I chew on how to automagically eliminate duplicate transclusions, I have at least a prototype of viewing such a problem when one exists.
With Tidgraph, a sample:
Main Tiddler’s text body has:
Both tiddlers A and B have:
Tiddler C has:
(include Main Tiddler)
Tiddler D has:
In the graph, the red line from tiddler B to C let’s me know that C is twice involved in the transclusion tree. The “CIRCULAR REFERENCE!!!” let’s me know that C is transcluding “Main Tiddler”. The red line between D and A (with arrow pointing to A) let’s me know that A is twice involved in the transclusion tree (and in this case is a circular reference too).
Again, if anybody knows of another way to get this information (graph or text-only, either are A-1), please let me know!