Mr. Johnson (talk | contribs) (Created page with "{{Documentation}} <includeonly><onlyinclude>{{#switch:{{lc:{{{1|}}}}} | mandatory = mandatory {{{2|}}} parameter | optional = optional {{{2|}}} parameter | no | none = no parameters | #default = {{Error|{{Code|{{{1|}}}}} is not a valid parameter for {{Template|Parameter}}.}} }} {{#ifeq:{{#titleparts:{{FULLPAGENAME}}||-1}}|Documentation|Category:Template Documentation| {{#switch:{{lc:{{{1|}}}}} | mandatory = Category:Templates with Mandatory Parameters | optional...") |
(No difference)
|
Latest revision as of 21:35, 17 November 2023
Template:Parameter
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, arbitrary text describing the parameter, typically something like string
or integer
.
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 Templates without Parameters category and returns: no parameters
The optional parameter is inserted between the two words. For instance, {{Parameter|optional|magenta}}
returns: optional magenta parameter
The documentation above was transcluded from Template:Parameter/Documentation. [ edit ]