ATTENTION! The process of updating WiKi to version Eco 10.x has begun. Those wishing to participate can find out more Information on our ECO Contribution Wiki Discord.
From April 26 to May 12, errors may occur in the Wiki, as we will be carrying out a major update to the information processing modules.

Template:Doc: Difference between revisions

From Eco - English Wiki
[unchecked revision][unchecked revision]
m (1 revision imported)
 
m (1 revision imported)
(No difference)

Revision as of 23:24, 6 December 2019

Template:Doc/start To use, create a sub-page from the template called doc, put

  1. REDIRECT Template:Template link

Template:Redirect category shell at the start of your documentation, and

  1. REDIRECT Template:Template link

Template:Redirect category shell at the end.

Go back to your main template page and put <noinclude>

  1. REDIRECT Template:Template link

Template:Redirect category shell</noinclude> on a newline after the end of the template. /doc pages will automatically be added to Category:Template documentation.

Optional parameters

clear

If your main template page has floating content and you would like to stop it going over the documentation, put {{doc/start|clear}} instead of

  1. REDIRECT Template:Template link

Template:Redirect category shell on your documentation page.
This is also useful for templates not using <includeonly>, as it will put some space between the template and the documentation box.

nodoc=1

If a template has no documentation and you don't know how to use it, put {{doc/start|nodoc=1}} (or if the template needs clear as well, {{doc/start|clear|nodoc=1}}) instead of

  1. REDIRECT Template:Template link

Template:Redirect category shell on your documentation page.
The documentation's background will become red to make it more noticeable, and the page will be added to Category:Templates with no documentation.

baddoc=1

Similar to nodoc, this is used to mark templates that do have documentation, but it isn't very good. This can mean it doesn't have enough examples, doesn't explain all the functions properly, or doesn't explain the point of the template properly.
The documentation's background will become yellow to make it more noticeable, and the page will be added to Category:Templates with bad documentation.

If both nodoc and baddoc are specified, baddoc will be ignored.