Difference between revisions of "Parameter"
Stratonian (talk | contribs) m (added <code> and <nowiki> tags to the default) |
Stratonian (talk | contribs) m |
||
Line 2: | Line 2: | ||
|;{{arrow}}'''{{{1}}}'''<nowiki>:</nowiki> {{{2|{{error|No parameter description was provided. Add a description parameter.}}}}}<!-- handle parameter name and description | |;{{arrow}}'''{{{1}}}'''<nowiki>:</nowiki> {{{2|{{error|No parameter description was provided. Add a description parameter.}}}}}<!-- handle parameter name and description | ||
-->:{{#ifeq:{{{3|}}}|{{{3}}}|Optional|Required}}.<!-- handle whether parameter is required | -->:{{#ifeq:{{{3|}}}|{{{3}}}|Optional|Required}}.<!-- handle whether parameter is required | ||
− | -->{{#if:{{{3|}}}| Defaults to "<code | + | -->{{#if:{{{3|}}}| Defaults to "<code>{{{3}}}</code>".}}<!-- handle parameter default |
-->{{#if:{{{4|}}}|:'''Notes''': {{{4}}}}}<!-- handle parameter notes | -->{{#if:{{{4|}}}|:'''Notes''': {{{4}}}}}<!-- handle parameter notes | ||
-->|{{error|No parameter name was provided. Add a name parameter.}}}}<!-- error if no name | -->|{{error|No parameter name was provided. Add a name parameter.}}}}<!-- error if no name | ||
--></includeonly><noinclude>{{Parameter/Documentation}}</noinclude> | --></includeonly><noinclude>{{Parameter/Documentation}}</noinclude> |
Revision as of 17:01, 24 March 2023
Description
Displays a documentation parameter. Used to ensure documentation is standardized.
Usage
{{parameter|<name>|<description>}}
{{parameter|<name>|<description>|<default>}}
{{parameter|<name>|<description>|<default>|<notes>}}
{{parameter|<name>|<description>|<4=notes>}}
Parameters
- 3: The default value of the parameter.
- Optional.
- Notes: If there is no default value, the parameter is assumed to be required. If the parameter is optional and has no default value, define the parameter but leave it blank.
Errors
No parameter description was provided. Add a description parameter.
No parameter name was provided. Add a name parameter.