68,426
edits
No edit summary |
No edit summary |
||
Line 2: | Line 2: | ||
== Details == | == Details == | ||
* This template takes another ''template-name'' and some associated [[ | * This template takes another ''template-name'' and some associated [[Pipe trick|pipe-tricked]] [[m:Parameter#Parameters|(numbered) parameters]] (or 'pass parameters'), and displays them as an 'example demonstration' of how the ''template-name'' template could be coded, literally. Its primary use is in instruction and documentation. | ||
* '''''Specifics:''''' Up to 10 pass parameters (numbered or nowiki-keywords) for the specified template are displayed as 'placeholders', and over 10 parameters can be displayed using a coded vertical-bar (as in "<small>&#124;</small>''...''"). A keyword parameter can be used with equals code &#61; or <nowiki>{{=}}</nowiki> or in nowiki-text: "<nowiki>size=10</nowiki>" or all parameters as a string in <nowiki>"<nowiki>"</nowiki> tags; see ''[[#Examples|Examples]]'' at bottom. For more details, see [[{{TALKPAGENAME}}|this talk]] page. | * '''''Specifics:''''' Up to 10 pass parameters (numbered or nowiki-keywords) for the specified template are displayed as 'placeholders', and over 10 parameters can be displayed using a coded vertical-bar (as in "<small>&#124;</small>''...''"). A keyword parameter can be used with equals code &#61; or <nowiki>{{=}}</nowiki> or in nowiki-text: "<nowiki>size=10</nowiki>" or all parameters as a string in <nowiki>"<nowiki>"</nowiki> tags; see ''[[#Examples|Examples]]'' at bottom. For more details, see [[{{TALKPAGENAME}}|this talk]] page. | ||
* '''''Exceptions:''''' If the intended template lists numerous parameters, then perhaps this template should really ''not'' be used, and just hardcode the usage with {{nowrap|<code><nowiki><code><nowiki></nowiki></code>}}, for example: {{nowrap|<code><nowiki><code><nowiki>{{Anytemplate|arg1=23|size=250px|</nowiki><var>other parameters...</var><nowiki>}}</nowiki></code></nowiki></code>}}. If a vertical display, with parameters on their own lines, is desired, this can also be laid out manually in this manner, or more rapidly done with {{nowrap|<code><nowiki><pre>...</pre></nowiki></code>}}. | * '''''Exceptions:''''' If the intended template lists numerous parameters, then perhaps this template should really ''not'' be used, and just hardcode the usage with {{nowrap|<code><nowiki><code><nowiki></nowiki></code>}}, for example: {{nowrap|<code><nowiki><code><nowiki>{{Anytemplate|arg1=23|size=250px|</nowiki><var>other parameters...</var><nowiki>}}</nowiki></code></nowiki></code>}}. If a vertical display, with parameters on their own lines, is desired, this can also be laid out manually in this manner, or more rapidly done with {{nowrap|<code><nowiki><pre>...</pre></nowiki></code>}}. |
edits