Jump to content

Module:Transclusion count/doc: Difference between revisions

From Wikipedia, the free encyclopedia
Content deleted Content added
create
 
Update
Line 1: Line 1:
{{Module rating |alpha}}
{{Module rating |alpha}}


Module replacement for {{tl|High-use/num}}. Uses bot-updated values from [[Special:PrefixIndex/Module:Transclusion_count/data/|subpages of Module:Transclusion_count/data/]] when available.
Fetches usage data for highly-trandscluded templates. Uses bot-updated values from [[Special:PrefixIndex/Module:Transclusion_count/data/|subpages of Module:Transclusion_count/data/]] when available.


== Usage ==
== Usage ==


<code><nowiki>{{</nowiki>#invoke:{{BASEPAGENAME}}|main|''number of transclusions''|''use + notation''|all-pages=|demo=}}</code>
<code><nowiki>{{</nowiki>#invoke:{{BASEPAGENAME}}|fetch|''number of transclusions''|''use + notation''|all-pages=|demo=}}</code>


* ''<code>number of transclusions</code>'': is either a static number of times the template has been transcluded, or the word "risk" (without quotes) to display "a very large number of" instead of the actual value. This value will be ignored if transclusion data is available for the current page.
* ''<code>number of transclusions</code>'': is a static number of times the template has been transcluded, to use when values cannot be read from the database. This value will be ignored if transclusion data is available for the current page.
* ''<code>use + notation</code>'': will display "#,###+" instead of "approximately #,###" when set equal to "yes" (without quotes). When used, values will be rounded down, instead of rounded to the nearest number with the appropriate number of significant figures.
* <code>all-pages=yes</code>: will also output what percentage of all pages use the template. This should only be used for very highly transcluded templates.
* <code>demo=''Template_name''</code>: will use the transclusion count for the template at [[Template:Template_name]] instead of detecting what template it is being used on. Capitalization must exactly match the value used in [[Special:PrefixIndex/Module:Transclusion_count/data/]].
* <code>demo=''Template_name''</code>: will use the transclusion count for the template at [[Template:Template_name]] instead of detecting what template it is being used on. Capitalization must exactly match the value used in [[Special:PrefixIndex/Module:Transclusion_count/data/]].



Revision as of 18:19, 11 November 2019


Fetches usage data for highly-trandscluded templates. Uses bot-updated values from subpages of Module:Transclusion_count/data/ when available.

Usage

{{#invoke:Transclusion count|fetch|number of transclusions|use + notation|all-pages=|demo=}}

  • number of transclusions: is a static number of times the template has been transcluded, to use when values cannot be read from the database. This value will be ignored if transclusion data is available for the current page.
  • demo=Template_name: will use the transclusion count for the template at Template:Template_name instead of detecting what template it is being used on. Capitalization must exactly match the value used in Special:PrefixIndex/Module:Transclusion_count/data/.