模組:Documentation/doc檢視原始碼檢視歷史
此頁面為 模块:Documentation 的說明文件
40px | 此Luazh-cn:模块; zh-tw:模組;在100,000個頁面+中使用。 為了避免困擾和不必要的服務器負載,所有變更都應該經過測試。請先在zh-cn:模块; zh-tw:模組;的/sandbox或者/testcases子頁面測試。測試過的內容可以一次更改。修改前請考慮至討論頁討論變更。 |
本模組已被保護。此為高度可見模組,其已用於大量條目或被頻繁替換引用。由於破壞或失誤會影響諸多頁面,即便細小的改動也可能導致大量服務器負載,因此已被保護,不可編輯。 |
This module displays a blue box containing documentation for templates, Lua modules, or other pages. The {{documentation}} template invokes it.
Normal usage
For most uses, you should use the {{documentation}} template; please see that template's page for its usage instructions and parameters.
Use in other modules
To use this module from another Lua module, first load it with require
:
local documentation = require('Module:Documentation').main
Then you can simply call it using a table of arguments.
documentation{content = 'Some documentation', ['link box'] = 'My custom link box'}
Please refer to the template documentation for usage instructions and a list of parameters.
Porting to other wikis
The module has a configuration file at Module:Documentation/config which is intended to allow easy translation and porting to other wikis. Please see the code comments in the config page for instructions. If you have any questions, or you need a feature which is not currently implemented, please leave a message at Template talk:Documentation to get the attention of a developer.