No edit summary |
No edit summary |
||
| Line 12: | Line 12: | ||
{{Code|<nowiki>{{Parameter|optional}}</nowiki>}} adds the template to the {{Category|Templates With Optional Parameters|end}} and returns: {{Return|{{Parameter|optional}}}} | {{Code|<nowiki>{{Parameter|optional}}</nowiki>}} adds the template to the {{Category|Templates With Optional Parameters|end}} and returns: {{Return|{{Parameter|optional}}}} | ||
{{Code|<nowiki>{{Parameter|no}}</nowiki>}} or {{Code|<nowiki>{{Parameter|none}}</nowiki>}} adds the template to the {{Category|Templates Without Parameters|end}} and returns: {{Return|{{Parameter|none}}}} | |||
Revision as of 13:27, 23 October 2022
Template:Parameter is used with in the template namespace to identify and categorize templates based on their usage of parameters.
Usage
It accepts one mandatory parameter, one of mandatory, optional, no, or none.
It also accepts one optional string parameter, any arbitrary text.
Return
It's invoked twice above, but for clarity sake...
{{Parameter|mandatory}} adds the template to the Templates With Mandatory Parameters category and returns:
mandatory parameter
{{Parameter|optional}} adds the template to the Templates With Optional Parameters category and returns:
optional parameter
{{Parameter|no}} or {{Parameter|none}} adds the template to the Category:Templates without Parameters category and returns:
no parameters
