m (try another method) |
(fix missing brace in templatedata, and reformat braces) |
||
(4 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
<includeonly><!</includeonly>-- This preload is based off the original documentation template's own documentation. You do not have to follow it exactly. --<includeonly>></includeonly> | <includeonly><!</includeonly>-- This preload is based off the original documentation template's own documentation. You do not have to follow it exactly. --<includeonly>></includeonly> | ||
==Description== | ==Description== | ||
<!-- | <!--Summary of what the main function of the template is--> | ||
This template can be used to... | This template can be used to... | ||
==Usage== | ==Usage== | ||
Line 20: | Line 16: | ||
==Parameters== | ==Parameters== | ||
<includeonly><templatedata>{ "description": "","params": { | <!--Search for Help:TemplateData if you need help formatting this--> | ||
<includeonly><templatedata> | |||
{ | |||
"description": "The template does X and is used when you want Y.", | |||
"format": "inline", | |||
"params": { | |||
"parameter1": { | "parameter1": { | ||
"label": "Fancy_Name", | "label": "Fancy_Name", | ||
"type": " | "type": "string", | ||
"description": "Explanation", | "description": "Explanation", | ||
"example": "Example_Input", | "example": "Example_Input", | ||
Line 30: | Line 31: | ||
"parameter2": { | "parameter2": { | ||
"label": "Fancy_Name", | "label": "Fancy_Name", | ||
"type": " | "type": "string", | ||
"description": "Explanation", | "description": "Explanation", | ||
"example": "Example_Input", | "example": "Example_Input", | ||
"default": "Default_If_Static" | "default": "Default_If_Static" | ||
}} | } | ||
<!--The following | } | ||
} | |||
</templatedata></includeonly> | |||
<!--The following comment holds a template you can copy-paste or reference with all options listed--> | |||
<!-- | |||
}, | }, | ||
" | "parameterN": { | ||
"label": "Fancy_Name", | "label": "Fancy_Name", | ||
"aliases": ["Other_Name1","Other_Name2"], | "aliases": ["Other_Name1","Other_Name2"], | ||
"type": "Choose one of: number, string, line(no line breaks), content(formatted wikitext), boolean, url(https://example.com), date, wiki-page-name, wiki-file-name, wiki-user-name, wiki-template-name | "type": "Choose one of: number, string, line(no line breaks), content(formatted wikitext), boolean, url(https://example.com), date, wiki-page-name, wiki-file-name, wiki-user-name, wiki-template-name", | ||
"description": "Explanation", | "description": "Explanation", | ||
"example": "Example_Input", | "example": "Example_Input", | ||
Line 50: | Line 55: | ||
"deprecated": "What_To_Use_Instead", | "deprecated": "What_To_Use_Instead", | ||
"inherits": "put another parameter name here to copy its properties (gets overwritten by new ones)", | "inherits": "put another parameter name here to copy its properties (gets overwritten by new ones)", | ||
IMPORTANT, | --> | ||
<!-- ## IMPORTANT ## | |||
TemplateData uses JSON, if you don't know how to write JSON then heavily reference other template docs. | |||
Search for Help:TemplateData and read that page for more help. | |||
If you still can't figure out an error, save the page with the error and try notifying someone, maybe by adding [[Category:Maintenance]]--> | |||
==Sample== | ==Sample== | ||
The following input: | The following input: | ||
<pre>{{Example|param=value|pa..}}</pre> | |||
<pre> | |||
{{Example|param=value|pa..}} | |||
</pre> | |||
Produces: | Produces: | ||
<includeonly><</includeonly>noinclude> | <Example here> | ||
<includeonly><</includeonly>includeonly>__NOEDITSECTION__<includeonly><</includeonly>/includeonly> | |||
<includeonly><</includeonly>noinclude><includeonly>[[Category:Template documentation]]</includeonly><includeonly><</includeonly>/noinclude> | |||
<includeonly><</includeonly>includeonly>__NOEDITSECTION__ | |||
<includeonly>[[Category:Templates]]</includeonly> | |||
<includeonly><</includeonly>/includeonly><noinclude>[[Category:Preload]]</noinclude> |
Latest revision as of 20:42, 23 September 2024
-- This preload is based off the original documentation template's own documentation. You do not have to follow it exactly. --
Description
This template can be used to...
Usage
Parameters
Sample
The following input:
{{Example|param=value|pa..}}
Produces:
<Example here>
noinclude>/noinclude> includeonly>
/includeonly>