This page is part of a static HTML representation of the TiddlyWiki at https://tiddlywiki.com/

TextReference

21st March 2023 at 1:04pm

A TextReference is a general purpose way to describe a fragment of text as either a field of a tiddler, or an index within a data tiddler.

In different situations, text references can be used to retrieve values, or to specify a value that should be modified.

A TextReference consists of several parts:

  • The title of the target tiddler. If omitted, it defaults to the Current Tiddler
  • Either one of:
    • The name of a field (marked with !!)
    • The name of an index within a data tiddler (marked with ##)
  • If both the field and index are omitted, the text field is used as the default

Most of the parts of a text reference can be optional:

  • tiddlerTitle - the title field of the specified tiddler
  • tiddlerTitle!!field - a tiddler field (eg, modified, modifier, type etc)
  • !!field - a field of the current tiddler
  • tiddlerTitle##propertyIndex - extracts a named property from DataTiddlers

Text references can be used in several places:

Tip
Note the distinction between a text reference such as foo!!bar and a transclusion of a text reference such as {{foo!!bar}}