“模块:Yesno/doc”与“模板:Tl/doc”:页面之间的差异

来自NebulaeWiki
< 模块:Yesno(页面间差异)
(已保护“模块:Yesno/doc”([编辑=仅允许管理员](无限期)[移动=仅允许管理员](无限期)))
 
(已保护“模板:Tl/doc”([编辑=仅允许管理员](无限期)[移动=仅允许管理员](无限期)))
 
第1行: 第1行:
{{Documentation}}
{{Documentation}}
{{Wikipedia template}}
This template is used to display a template name as a link surrounded by braces. See [[Wikipedia:Template:Tl|Template:Tl]] on Wikipedia for more details.


'''Module:Yesno''' provides a consistent interface for processing boolean or boolean-style string input. While Lua allows the <code>true</code> and <code>false</code> boolean values, wikicode templates can only express boolean values through strings such as "yes", "no", etc. This module processes these kinds of strings and turns them into boolean input for Lua to process. It also returns <code>nil</code> values as <code>nil</code>, to allow for distinctions between <code>nil</code> and <code>false</code>. The module also accepts other Lua structures as input, i.e. booleans, numbers, tables, and functions. If it is passed input that it does not recognise as boolean or <code>nil</code>, it is possible to specify a default value to return.
==Syntax==
: {{tl|template}} <!--
    --><big></big> {{tl|template}}
<includeonly>
[[Category:Internal link templates|{{PAGENAME}}]]
</includeonly>
<noinclude></noinclude>

2023年9月23日 (六) 22:32的最新版本

This template is used to display a template name as a link surrounded by braces. See Template:Tl on Wikipedia for more details.

Syntax

{{template}} {{template}}