Difference between revisions of "Lylat Wiki:Template Standards"

updated
(updated)
 
(32 intermediate revisions by 5 users not shown)
Line 1: Line 1:
Templates are used to make it easier on a page to store infromation, as some of the information is stored elsewhere. Templates are used to make it easier on the editors, as to provide a common content and save time instead of placing the exact same content in different locations. Templates are also used as tools to help direct community involvement for the maintenance of an article. But what makes a "Good Template"?  
{{shortcuts|LW:TS}}
{{Standards}}
{{draft-policy}}
Templates are used to make it easier on a page to store information, as some of the information is stored elsewhere. Templates are used to make it easier on the editors, as to provide a common content and save time instead of placing the exact same content in different locations. Templates are also used as tools to help direct community involvement for the maintenance of an article. But what makes a "Good Template"?  


While there will never be an absolute way to say "this is a good template", there are certain things we should expect from each template and there respective pages (such as documentation and usage information). Due to the nature and infinitely diverse uses of templates, having a common expectation for each page does help standardize the pages.  
While there will never be an absolute way to say "this is a good template", there are certain things we should expect from each template and there respective pages (such as documentation and usage information). Due to the nature and infinitely diverse uses of templates, having a common expectation for each page does help standardize the pages.  
Line 14: Line 17:
=== Sections ===
=== Sections ===
If a template generates a section breaker (through <nowiki>===</nowiki>  
If a template generates a section breaker (through <nowiki>===</nowiki>  
Section headers </nowiki>), then that section header is not only subject to these guidelines, but also to the guidelines that the receiving page(s) are under.  
Section headers <nowiki>===</nowiki>), then that section header is not only subject to these guidelines, but also to the guidelines that the receiving page(s) are under.  


For more, please see: [[Lylat Wiki:Section Standards]].  
For more, please see: [[Lylat Wiki:Section Standards]].


=== Tables ===
=== Tables ===
=== Categories ===
Which category does this template belong to? Will it play well with similar templates, sorting itself into place?
Typically, one template will be a member of two templates, both of which are an [[LW:Area|area of the wiki]]. To help decide what the template should be sorted under, we've come up with the template: {{t|cat}}. With this template, a page automatically becomes a member of up to five categories, each one serving as the others sortkey. For more information, see [[Help:Categories]].
Here are some examples of template categories you may consider putting your template under:
* [[:Category:Article Templates]]
* [[:Category:Category Templates]]
* [[:Category:Character Templates]]
* [[:Category:Color Templates]]
* [[:Category:Company Templates]]
* [[:Category:Discussion Templates]]
* [[:Category:Featured Templates]]
* [[:Category:File Templates]]
* [[:Category:Infobox Templates]]
* [[:Category:Notice Templates]]
* [[:Category:Stage Templates]]


== Documentation ==
== Documentation ==
=== Documetiaon Shell ===
Each template should have some kind of documentation telling you how to use it.
 
In order to generate a documentation page, place <nowiki><noinclude>{{doc}}</noinclude></nowiki> at the very bottom of the template, and a <code>/doc</code> red link will show up when you save. Click this link to go to the documentation subpage.
 
On the actual documentation page, we recommend you put the following:
* a Documentation Shell, which is intended to provide easier access to the template page, the name of the template, and related templates.
* The two sections:  Purpose and Usage. 
 
=== Documentation Shell ===
{{templates-table-top}}
|-
| [[Template:documentation shell|documentation shell]]
|
<pre>
<pre>
{{documentation shell
{{documentation shell
| name = Documentation shell
| name =  
| info = The shell for all documentation pages.
| info =  
| see also = taken from [http://www.grifkuba.org/main/wiki/index.php?title=Template:Documentation_shell/doc source] on Februrary 27th, 2010.
| see also =  
}}
}}
</pre>
</pre>
| Use this template for all characters.
|-
{{templates-table-bottom}}
|}
=== Sections ===
=== Sections ===
<pre>
<pre>
==Purpose==
==Purpose==
==Usage==
==Usage==
===Example===
<pre>
{{Template Name
| param 1 =
| param 2 =
| param 3 =
}}
&lt;/pre> <!-- note: use an actual less than sign than the html equailavent &amp;lt; -->
=== Parameters ===
=== Parameters ===
{| class="wikitable" width=100%
{{Parameters-table-top}}
|+
|-
|-
! Name
| <!-- one row per parameter -->  
! Description
! Values-Related Stuff <!-- for if anything happens becuase a specific value related is not entered
|-
| <!-- one row per paramter -->  
|  
|  
|  
|  
|-
| colspan=3 | none <!-- for no parameters -->
|-
|-
{{parameters-table-bottom}}
{{parameters-table-bottom}}
|}  
|}  
<noinclude>[[Category:Documentation|{{PAGENAME}}]]</noinclude></pre>


==Example==
<includeonly>
<!-- cats -->
</includeonly>
<noinclude>[[Category:Documentation]]</noinclude></pre>
== Maintenance ==
== Actions ==
== Discussions ==
== Discussions ==
== Typical Types of Templates ==
== Typical Types of Templates ==
Line 61: Line 101:
=== Shortcuts ===
=== Shortcuts ===
=== Maintenance ===
=== Maintenance ===
[[Category:Templates|{{PAGENAME}}]]
8,161

edits