Template:Js doclink

Template documentation


This template creates a link to MediaWiki Core's auto-generated Javascript API documentation at https://doc.wikimedia.org/mediawiki-core/master/js/

Usage

Link to a class or method, with optional custom link text.

{{js doclink|mw.user}}mw.user

{{js doclink|mw.user|text=a widget}}a widget

{{js doclink|mw.user|method=getId}}mw.user.getId()

{{js doclink|mw.user|method=getId|text=some method}}some method

TemplateData

This is the TemplateData documentation for this template used by VisualEditor and other tools.

Js doclink

Category:Templates using TemplateData

Link to API documentation at docs.wikimedia.org

Template parameters

This template prefers inline formatting of parameters.

ParameterDescriptionTypeStatus
11

no description

Stringrequired
JS class nameclass

no description

Example
mw.user
Stringoptional
JS method namemethod

no description

Example
getId
Stringoptional
Link texttext

no description

Stringoptional

See also

Category:External link templates Category:Pages using the JsonConfig extension Category:Templates using TemplateData