Update Macro Definitions in WikiText.tid (#7201)

Ref: https://talk.tiddlywiki.org/t/requesting-macro-massage-willing-to-donate-50-to-tw/5833/17

Add explanation for single line nested macro
This commit is contained in:
Mohammad Rahmani 2023-01-11 22:27:21 +03:30 committed by GitHub
parent 9c70ee34d4
commit 494ee984f8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 12 additions and 0 deletions

View File

@ -98,5 +98,17 @@ Note that the textual substitution of macro parameters that occurs when the oute
Parameters of nested macros can also be accessed via the `<<__variablename__>>` syntax. As ordinary variables, these parameters are available within nested child macros (and grandchildren etc).
For the one-liner macro definition, the `\end` remains unnecessary for the inner macro. For example
<<wikitext-example-without-html src:"""\define special-button(caption:"Click me")
\define actions() <$action-sendmessage $message="tm-notify" $param="HelloThere"/>
<$button actions=<<actions>>>
$caption$
</$button>
\end special-button
<<special-button>>
""">>
A more formal [[presentation|Macro Definition Syntax]] of this syntax is also available.