Template:Dochead/doc: Difference between revisions
ArrowHead294 (talk | contribs) mNo edit summary |
ArrowHead294 (talk | contribs) No edit summary |
||
Line 17: | Line 17: | ||
On modules, unless <code>header=none</code> is passed, a header will appear which points to the template invoked: | On modules, unless <code>header=none</code> is passed, a header will appear which points to the template invoked: | ||
: '''Note:''' Do not invoke this module directly. Use the corresponding template instead: | : '''Note:''' Do not invoke this module directly. Use the corresponding template instead: [[Template:{{ROOTPAGENAME}}]] | ||
The linked template can be changed by passing <code>temp=</code> followed by the name of the template. | |||
=== See also === | === See also === |
Revision as of 18:44, 10 July 2024
This template automatically inserts the default documentation header:
Documentation transcluded from /doc
onto the main pages for certain items (mostly templates and modules), while also providing a link to the documentation subpage.
The header is wrapped in a <span>
element so it can be hidden on documentation pages but visible on main pages where they are transcluded.
It also places items inside their respective categories, which eliminates the need to do this manually. Currently, it is configured to place templates inside Category:Templates and modules inside Category:Lua modules.
Usage
This template is invoked by placing {{dochead}}
at the top of a module or template's /doc
subpage.
On modules, unless header=none
is passed, a header will appear which points to the template invoked:
- Note: Do not invoke this module directly. Use the corresponding template instead: Template:Dochead
The linked template can be changed by passing temp=
followed by the name of the template.
See also
- Template:Doc head Wikipedia – Similar template, used mainly for templates borrowed from Wikipedia.