更多操作
无编辑摘要 |
无编辑摘要 |
||
第1行: | 第1行: | ||
<!-- 转自Dustloop This page was last edited on 10 August 2023, at 23:59. --><noinclude>{{doc/start}} | <!-- 转自Dustloop This page was last edited on 10 August 2023, at 23:59. --><noinclude>{{doc/start}} | ||
本模板帮助创建模板说明子页面'''''/文档''''',请将{{Tl|Doc/start}}放在文档的头部,将{{Tl|Doc/end}}放在文档的末尾。 | |||
回到模板主页面,在源代码的最后附上<code><noinclude>{{Tl|Doc}}</noinclude></code>即可。模板说明子页面'''''/doc'''''将被自动加入[[:分类:Documentation templates]]。 | |||
== Optional parameters == | == Optional parameters == |
2024年12月8日 (日) 15:49的版本
本模板帮助创建模板说明子页面/文档,请将{{Doc/start}}
放在文档的头部,将{{Doc/end}}
放在文档的末尾。
回到模板主页面,在源代码的最后附上<noinclude>
即可。模板说明子页面/doc将被自动加入分类:Documentation templates。
{{Doc}}
</noinclude>
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 {{doc/start}}
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 {{doc/start}}
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.