Template:Documentation/doc: Difference between revisions

From Roat Pkz
Jump to navigation Jump to search
No edit summary
Tag: Reverted
No edit summary
Tag: Manual revert
 
Line 6: Line 6:


==Usage==
==Usage==
Place {{t|Documentation}} at the top of the documentation page, then transclude <code><nowiki>{{/doc}}</nowiki></code> directly from the main template page, within <nowiki><noinclude></nowiki> tags.
Place {{t|documentation}} at the top of the documentation page, then transclude <code><nowiki>{{/doc}}</nowiki></code> directly from the main template page, within <nowiki><noinclude></nowiki> tags.


If the page to be documented is a subpage, use {{t|Documentation|pagename of page to be documented}} at the top of the documentation page. For example, Template:Foo/bar's documentation page would use {{t|Documentation|Template:Foo/bar}}.
If the page to be documented is a subpage, use {{t|documentation|pagename of page to be documented}} at the top of the documentation page. For example, Template:Foo/bar's documentation page would use {{t|documentation|Template:Foo/bar}}.


==Note==
==Note==
This template links to a /doc that may appear useless, however, it exists in order to link navboxes and userboxes to their base template's documentation.  
This template links to a /doc that may appear useless, however, it exists in order to link navboxes and userboxes to their base template's documentation.  
<includeonly>[[Category:Template Documentation| ]]</includeonly>
<includeonly>[[Category:Template documentation| ]]</includeonly>

Latest revision as of 23:09, 28 March 2024

This is a documentation subpage for Template:Documentation.
It contains usage information, categories, and other content that is not part of the original template page.
Template:Documentation invokes function doc in Module:Documentation using Lua.
{{#replace:Template:Documentation/doc|/doc}} invokes Module:Documentation using Lua.

{{Documentation}} is transcluded in template/module documentation pages. This template should only be used on subpages titled "doc".

This is not the template of the same name from Wikipedia and it is not used in the same way.

Usage

Place {{documentation}} at the top of the documentation page, then transclude {{/doc}} directly from the main template page, within <noinclude> tags.

If the page to be documented is a subpage, use {{documentation|pagename of page to be documented}} at the top of the documentation page. For example, Template:Foo/bar's documentation page would use {{documentation|Template:Foo/bar}}.

Note

This template links to a /doc that may appear useless, however, it exists in order to link navboxes and userboxes to their base template's documentation.