User:Frietjes/templatecompare

Why does this script exist?
It may be useful to compare the parameters used by two (or three) different templates. Note that this only works for templates which explicitly use template arguments, and not for LUA-based templates where the template parameters are passed implicitly.

How to install
To install on another Wikipedia, use
 * 1) Open your common.js script page in edit mode.
 * 2) Paste the following line:
 * 3) Reload the script page (press   or the equivalent for your browser).

How to use

 * 1) Navigate to [//en.wikipedia.org/w/index.php?title=Special:TemplateCompare Special:TemplateCompare]. The page should briefly say "No such special page" before changing to "Template compare tool".  If continues to say "No such special page", something went wrong.
 * 2) Add the names of two (or three) templates in the top text window, with each template on a separate line and including the Template: prefix.
 * 3) Press the "Compare" button
 * 4) * You will see a pop-up alert when the script finishes processing each template
 * 5) * You will see a pop-up alert with the script finishes processing the last template
 * 6) A table showing the comparison of parameters will show below the "Compare" button along with cut-and-paste wikitext for the table.

Caveats
If you get a "Did not finish processing" warning, report this on the talk page and ping Frietjes so it can be fixed (or a reason can be given for not fixing it).

Do not assume that the list of parameters generated by this tool is a full list of working, supported parameters for a given template. This tool looks for instances of parameters used in the template. A parameter that is used may not actually be supported by the template; the parameter name may exist only in template code that checks for the existence of deprecated or no-longer-supported parameters, for example.