mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2025-04-12 05:43:16 +00:00
Docs update
This commit is contained in:
parent
7397f4fa3a
commit
2a1542c4e5
editions/tw5.com/tiddlers/filters/syntax
@ -3,7 +3,7 @@ from-version: 5.3.7
|
||||
modified: 20250307212252946
|
||||
rp-input: all titles from previous filter runs
|
||||
rp-output: an empty title list is always returned from the "let" filter run prefix
|
||||
rp-purpose: assign the result of a filter run to a variable
|
||||
rp-purpose: assign the results of a filter run to a variable
|
||||
tags: [[Named Filter Run Prefix]]
|
||||
title: Let Filter Run Prefix
|
||||
type: text/vnd.tiddlywiki
|
||||
@ -18,6 +18,7 @@ type: text/vnd.tiddlywiki
|
||||
[[run|"Filter Run"]]
|
||||
"""/>
|
||||
|
||||
The `:let` filter run prefix assigns the first result of a filter run to a variable that is made available to the remaining [[filter runs|Filter Run]] in the [[filter expression|Filter Expression]]. If the filter run does not return any results then the variable is set to an empty string.
|
||||
The `:let` filter run prefix assigns the result list of a filter run to a variable which is made available to the remaining [[filter runs|Filter Run]] in the [[filter expression|Filter Expression]]. Only the first item in the result list is returned when the variable is accessed in the usual way (or an empty string if the result list is empty). The special [varlist Operator] is used to access all the items in the result list.
|
||||
|
||||
Within the filter run the [[all Operator]] with an empty parameter retrieves all the titles from the previous filter runs, instead of the usual behaviour of retieving all the titles that were passed to the filter expression.
|
||||
|
||||
Within the filter run the [[all Operator]] with an empty parameter retrieves all the titles from the previous filter runs, instead of the usual behaviour of retieving all the titles that were passed to the filter expression.
|
@ -0,0 +1,14 @@
|
||||
caption: varlist
|
||||
created: 20250307212252946
|
||||
modified: 20250307212252946
|
||||
op-input: ignored
|
||||
op-output: the list items stored in the variable
|
||||
op-parameter: the name of a variable
|
||||
op-purpose: retrieve the value of a variable as a list
|
||||
tags: [[Filter Operators]] [[Selection Constructors]]
|
||||
title: varlist Operator
|
||||
type: text/vnd.tiddlywiki
|
||||
|
||||
The parameter specifies the name of a variable that has been assigned a list of items by a [[let filter run prefix|Let Filter Run Prefix]]. The operator retrieves all the list items.
|
||||
|
||||
<<.operator-examples "varlist">>
|
Loading…
x
Reference in New Issue
Block a user