Template talk:Yesno: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
mNo edit summary
No edit summary
Line 2: Line 2:


I feel like this template is just bad practice. There is no need to have 5 different ways to write yes/no. Simple switch statement and using always 1/0/#default is enough and is a lot less expensive than calling template with parameters and is more readable since #switch is well explained and documented while with this you need to look at what this particular template does --[[User:Nescius|Nescius]] ([[User talk:Nescius|talk]]) 13:47, 1 August 2024 (PDT)
I feel like this template is just bad practice. There is no need to have 5 different ways to write yes/no. Simple switch statement and using always 1/0/#default is enough and is a lot less expensive than calling template with parameters and is more readable since #switch is well explained and documented while with this you need to look at what this particular template does --[[User:Nescius|Nescius]] ([[User talk:Nescius|talk]]) 13:47, 1 August 2024 (PDT)
:It's a very inexpensive template that doesn't really hurt anything (trying it on my sandbox, it takes .938 seconds to use it 1,000 times), and it standardizes a certain set of values that are used on Wikipedia and other wikis very regularly (in fact, Module:Yesno is the second most commonly used module on English Wikipedia, and it along with template:yesno are used more than any single template/module). Allowing for most reasonable variations of "yes" and "no" and using all of the same values as Wikipedia makes it much easier for newcomers to edit pages.

Revision as of 17:47, 1 August 2024

unnecessary template

I feel like this template is just bad practice. There is no need to have 5 different ways to write yes/no. Simple switch statement and using always 1/0/#default is enough and is a lot less expensive than calling template with parameters and is more readable since #switch is well explained and documented while with this you need to look at what this particular template does --Nescius (talk) 13:47, 1 August 2024 (PDT)

It's a very inexpensive template that doesn't really hurt anything (trying it on my sandbox, it takes .938 seconds to use it 1,000 times), and it standardizes a certain set of values that are used on Wikipedia and other wikis very regularly (in fact, Module:Yesno is the second most commonly used module on English Wikipedia, and it along with template:yesno are used more than any single template/module). Allowing for most reasonable variations of "yes" and "no" and using all of the same values as Wikipedia makes it much easier for newcomers to edit pages.