1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2024-11-24 18:47:20 +00:00
TiddlyWiki5/editions/tw5.com/tiddlers/variables/WidgetVariable_ currentTiddler.tid
2014-10-03 07:15:06 +08:00

22 lines
914 B
Plaintext

caption: currentTiddler
created: 20141001232824187
modified: 20141002161518301
tags: Variables
title: WidgetVariable: currentTiddler
type: text/vnd.tiddlywiki
! Mechanism
The ''currentTiddler'' variable containes the title of the current tiddler.
The ListWidget assigns the list result to the ''currentTiddler'' variable, unless the `variable` attribute is specified.
A couple of [[Widgets]] and [[Macros]] by default apply to the tiddler according to the ''currentTiddler'' variable.
The TranscludeWidget (or WikiText `{{||TemplateTitle}}`) transcludes a tiddler without changing the ''currentTiddler'' variable.
! Using currentTiddler Variable
These mechanisms together allow you to write references like `<$view field="title" format="link"/>` in TemplateTiddlers or inside the ListWidget hierarchy without explicitly specifying the tiddler that it applies to.
See also [[WidgetVariable: storyTiddler]]