Alternative to <$list> for doing wikitext if then macros

36 views
Skip to first unread message

FrD

unread,
Jul 17, 2018, 5:56:30 AM7/17/18
to TiddlyWiki
Hi,

Several times in this group someone wants to build a if then (else) wikitext macro.
The solution with the <$list> widget works fine. But the code is often complicated.

I just wanted to point out that sometimes the use of the <$importvariables> widget is simpler.

Instead of writing an (often) convoluted macro to treat two or three different cases with the <$list> widget, you can write two or three different simple macros in different tiddlers and select the tiddler you want to import based on the value for instance of a checkbox in an interface.
It works fine when the different cases are based on the value the user chooses via a select or a checkbox or a radio button. And in this case I feel it's a more TWish(?) way of doing things (with filters and tiddlers).

Another tool in the TW toolbox !

Regards

FrD
Reply all
Reply to author
Forward
0 new messages