Module talk:Yesno: Difference between revisions

Content deleted Content added
m Replaced deprecated <source> tags with <syntaxhighlight> (via WP:JWB)
Tags: Reverted Mobile edit Mobile web edit
Line 249:
::This can also mostly be handled by specifying the default parameter (i.e. <syntaxhighlight lang="lua" inline>myvariable = yesno(value, false)</syntaxhighlight>), although this does leave the case <syntaxhighlight lang="lua" inline>yesno(nil, false)</syntaxhighlight>, which evaluates to <syntaxhighlight lang="lua" inline>nil</syntaxhighlight>. The reason I originally programmed the module this way is so that it can be mostly backwards-compatible with [[Template:Yesno]], which it is intended to replace. Originally the plan was to do a straight conversion of [[Template:Yesno]] to Lua, but it turned out that doing that was actually slower than just using the template, given the template's simplicity and the initial cost of switching between PHP and Lua. So instead this module became Lua-only, with most of the behaviour of [[Template:Yesno]]. The intention there was that module writers could easily incorporate it into modules that convert more complex templates without having to change the template logic too much. — '''''[[User:Mr. Stradivarius|<span style="color: #194D00; font-family: Palatino, Times, serif">Mr.&nbsp;Stradivarius</span>]]''''' <sup>[[User talk:Mr. Stradivarius|♪&nbsp;talk&nbsp;♪]]</sup> 22:11, 23 December 2021 (UTC)
:::OK, thx. I can use this code solution with confidence now, no research-&-test needed. Might as well add it to the /doc. -[[User:DePiep|DePiep]] ([[User talk:DePiep|talk]]) 16:35, 24 December 2021 (UTC)
 
== FaadfProtected edit request on 20 June 2022 ==
 
{{Scfsdggrgvh
Fvgffdbnygcacvhdcccbbnmvfdcffehbnjjnjjtfxgdfrvcxxxgrfaccvjtsxedit fully-protected|Module:Yesno|answered=no}}
[[Special:Contributions/119.160.68.39|119.160.68.39]] ([[User talk:119.160.68.39|talk]]) 18:30, 20 June 2022 (UTC)