This is a stripped-down version of a single section of Grok TiddlyWiki, optimized for fast loading and readability by search engines. Some features are missing.

For the full Grok TiddlyWiki experience, please visit the wiki version of this page.

Ex:WikipediaLinkTemplate/answer

22nd November 2020 at 10:59am

First, create a tiddler called WikipediaMetadata and set its url field to https://en.wikipedia.org/wiki/. (You could also make a tiddler containing only the URL, in the text field, and create other tiddlers if you needed to maintain other information about Wikipedia; it's up to you what makes the most sense.)

Then in WikipediaLinkTemplate:

<a class="tc-tiddlylink-external" href={{{ [{WikipediaMetadata!!url}addsuffix<articleName>] }}}><<articleName>></a>

And to use this tiddler:

<$set name="articleName" value="Aardvark">
  {{WikipediaLinkTemplate}}
</$set>

Notice that treating the WikipediaLinkTemplate as a template by placing || prior to its name in the transclusion is not necessary, as it does not access any of the fields of the current tiddler.

Go to question: Ex:WikipediaLinkTemplate