Content deleted Content added
Wikify table; transparent background to highlight code |
HouseBlaster (talk | contribs) m HouseBlaster moved page Template:Tlsc/doc to Template:Template link code with subst/doc: expand template name per WP:TPN |
||
(5 intermediate revisions by 5 users not shown) | |||
Line 1:
{{Documentation subpage}}
{{High-use}}
<!-- PLEASE ADD CATEGORIES AND INTERWIKIS AT THE BOTTOM OF THIS PAGE -->
This is the '''{{tlc|tlsc}}''' template.
This page also provides the full documentation for the
== Purpose and naming ==
When a template name with braces is to be shown in documentation, the braces have to be escaped in some way so it doesn't become an actual call to the template. Instead of using <code><nowiki></nowiki></code> tags you can write it more simply and concisely by using the {{tlc|tlsc}}
These templates work similarly to {{tlc|tls}} and {{tlc|tlsp}}, but don't make the template name into a link. When writing documentation you might want to avoid a lot of unnecessary links, since they can decrease readability. So on the first occurrence of a template name use {{tlx|tls}} or {{tlx|tlsp}}, and then use {{tlc|tlsc
{| class="wikitable"
Line 20 ⟶ 21:
| {{tlc|tlsc}}
| '''T'''emplate '''l'''ink '''s'''ubstitution '''c'''ode
| Uses the <code><nowiki><code>...</code></nowiki></code> tags meant for showing programming code. Essentially the non-linking equivalent of {{tlx|tlsx}}.
|-
| {{tlc|tlsf}}
Line 31 ⟶ 28:
|}
The
===Basic operation===
Line 38 ⟶ 35:
:{{tlc|tlsc|name|parameters}} = {{tlsc|name|parameters}}
:{{tlc|tlsf|name|parameters}} = {{tlsf|name|parameters}}
Line 55 ⟶ 51:
* This template takes another ''template-name'' and some associated [[Help: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 here??? <!-- Coding details, other parameters (SUBST?), other notes? Cf. [[Template:Tlx]] -->
*Features of {{tlc|tlsc
** They show the "subst:" needed in order to substitute a template.
** They show a template name and up to eight parameters.
Line 99 ⟶ 95:
:<code><nowiki><nowiki>{{subst:name|one=a|two=b}}</nowiki></nowiki></code> = <nowiki>{{subst:name|one=a|two=b}}</nowiki>
:<code><nowiki><tt><nowiki>{{subst:name|one=a|two=b}}</nowiki></tt></nowiki></code> = <
:<code><nowiki><code><nowiki>{{subst:name|one=a|two=b}}</nowiki></code></nowiki></code> = <code><nowiki>{{subst:name|one=a|two=b}}</nowiki></code>
Line 106 ⟶ 102:
* {{tl|tlsc}} – Not linked, several parameters and text in <code><code></code></code> style.
* {{tl|tlsf}} – Not linked, several parameters and normal text style.
* {{tl|tls}} – Template link, no parameters and normal text style.
* {{tl|tlsp}} – Template link, several parameters and interwiki links.
* {{tl|tlsx}} – Template link, several parameters and interwiki links, <
<includeonly>{{Sandbox other||
<!-- CATEGORIES BELOW THIS LINE, PLEASE: -->
[[Category:Internal template-link templates]]
[[Category:
[[sl:Predloga:Tlsc]]
}}</includeonly>
|