Template:Documentation: Difference between revisions

From NARA
Jump to navigation Jump to search
NARA>Bsherr
(consistent with new substitution template format)
m (Remove some random crap from the Wikipedia import)
 
(2 intermediate revisions by the same user not shown)
Line 1: Line 1:
{{#invoke:documentation|main|_content={{ {{#invoke:documentation|contentTitle}}}}}}<noinclude>
<noinclude>
<!-- Add categories to the /doc subpage -->
</noinclude><includeonly>{{#invoke:documentation|main|_content={{ {{#invoke:documentation|contentTitle}}}}}}</includeonly><noinclude>
</noinclude>
{{documentation|content=
 
{{Lua|Module:Documentation}}
This template automatically displays a documentation box like the one you are seeing now, of which the content is sometimes transcluded from another page.
It is intended for pages which are transcluded in other pages, i.e. templates, whether in the template namespace or not.
 
==Usage== <!--T:2-->
 
===Customizing display=== <!--T:3-->
 
Overrides exist to customize the output in special cases:
 
* <nowiki>{{</nowiki>documentation{{!}}'''heading'''=<nowiki>}}</nowiki> - change the text of the "documentation" heading. If this is set to blank, the entire heading line (including the first [edit] link) will also disappear.
 
==Rationale==
 
This template allows any page to use any documentation page, and makes it possible to protect templates while allowing anyone to edit the template's documentation and categories.
 
}}
</noinclude><includeonly>{{#if:{{{content|}}}|
}}</includeonly>

Latest revision as of 17:21, 19 April 2023


Template documentation

This template automatically displays a documentation box like the one you are seeing now, of which the content is sometimes transcluded from another page. It is intended for pages which are transcluded in other pages, i.e. templates, whether in the template namespace or not.

Usage

Customizing display

Overrides exist to customize the output in special cases:

  • {{documentation|heading=}} - change the text of the "documentation" heading. If this is set to blank, the entire heading line (including the first [edit] link) will also disappear.

Rationale

This template allows any page to use any documentation page, and makes it possible to protect templates while allowing anyone to edit the template's documentation and categories.