Template:Param/doc: Difference between revisions
Jump to navigation
Jump to search
mNo edit summary |
mNo edit summary |
||
Line 1: | Line 1: | ||
{{Doc/subpage}} | |||
This template is for giving examples of template parameter source code which is useful in template documentation and talk page discussions of template code. | This template is for giving examples of template parameter source code which is useful in template documentation and talk page discussions of template code. | ||
==Parameters== | == Parameters == | ||
* {{Param}} – Parameter name. Displays the number 1 by default. | * {{Param}} – Parameter name. Displays the number 1 by default. | ||
* {{Param|2}} – additional text to be inserted after the parameter name, without a separator. Use {{Code|select=1||}} for separator. | * {{Param|2}} – additional text to be inserted after the parameter name, without a separator. Use {{Code|select=1||}} for separator. | ||
==Examples== | == Examples == | ||
* {{Code|select=1|{{Param}}}} → {{Param}} | * {{Code|select=1|{{Param}}}} → {{Param}} | ||
* {{Code|{{Param|text}}}} → {{Param|text}} | * {{Code|{{Param|text}}}} → {{Param|text}} | ||
* {{Code|{{Param|name|:<lang>}}}} → {{Param|name|:<lang>}} | * {{Code|{{Param|name|:<lang>}}}} → {{Param|name|:<lang>}} | ||
* {{Code|{{Param|2=&#124;text}}}} → {{Param|2=|text}} | * {{Code|{{Param|2=&#124;text}}}} → {{Param|2=|text}} |
Revision as of 00:12, 27 April 2023

This is a documentation subpage for Template:Param.
Don't forget to purge the contents of the base page upon creating or editing this subpage.
Don't forget to purge the contents of the base page upon creating or editing this subpage.
This template is for giving examples of template parameter source code which is useful in template documentation and talk page discussions of template code.
Parameters
- {{{1}}} – Parameter name. Displays the number 1 by default.
- {{{2}}} – additional text to be inserted after the parameter name, without a separator. Use | for separator.
Examples
- {{Param}} → {{{1}}}
- {{Param|text}} → {{{text}}}
- {{Param|name|:<lang>}} → {{{name|:<lang>}}}
- {{Param|2=|text}} → {{{1||text}}}