Template:TemplateData/entry/doc: Difference between revisions

From CrossCode Wiki
Jump to navigation Jump to search
(documentation)
 
(Completed)
Line 1: Line 1:
{{doc/start}}
{{doc/start}}
Template for creating a unified parameter format for templates


== About ==
Creates a list that displays Template parameter in a unified format
== Parameter ==
{{TemplateData|
{{TemplateData/entry|name=Parameter title|param=name|desc=Specify a title for a parameter of the template documentation|def=NULL|type=String|status=Required}}
{{TemplateData/entry|name=Parameter name|param=param|desc=Specify a name for a parameter of the template documentation|def=NULL|type=String|status=Required}}
{{TemplateData/entry|name=Parameter alias1|param=alias1|desc=Specify a alias for a parameter of the template documentation|def=NULL|type=String|status=Optional}}
{{TemplateData/entry|name=Parameter alias2|param=alias2|desc=Specify a alias for a parameter of the template documentation|def=NULL|type=String|status=Optional}}
{{TemplateData/entry|name=Parameter alias3|param=alias3|desc=Specify a alias for a parameter of the template documentation|def=NULL|type=String|status=Optional}}
{{TemplateData/entry|name=Parameter Description|param=desc|desc=Specify a description for a parameter of the template documentation|def=no description|type=String|status=Recommended}}
{{TemplateData/entry|name=Parameter Example|param=example|desc=Specify an example for a parameter of the template documentation|def=no example|type=String|status=Recommended}}
{{TemplateData/entry|name=Parameter type|param=type|desc=Specify a type for a parameter of the template documentation|def=NULL|type=String|status=Required}}
{{TemplateData/entry|name=Parameter status|param=status|desc=Specify a status for a parameter of the template documentation (Required, Recommended, Optional)|def=NULL|type=String|status=Required}}
}}
== Examples ==
'''Complete example:'''
{{TemplateData|
{{TemplateData/entry|name=Example name|alias1=Example alias 1|alias2=Example alias 2|alias3=Example alias 3|param=example param|desc=example description|def=NULL|example=xyz|type=String|status=Required}}
}}
<pre>
{{TemplateData|
{{TemplateData|
{{TemplateData/entry|name=Parameter title|param=name|desc=Specify a title for a parameter of the template documentation|type=String|status=Required}}
{{TemplateData/entry|name=Example name|alias1=Example alias 1|alias2=Example alias 2|alias3=Example alias 3|param=example param|desc=example description|def=NULL|example=xyz|type=String|status=Required}}
{{TemplateData/entry|name=Parameter name|param=param|desc=Specify a name for a parameter of the template documentation|type=String|status=Required}}
{{TemplateData/entry|name=Parameter Description|param=desc|desc=Specify a description for a parameter of the template documentation|type=String|status=Recommended}}
{{TemplateData/entry|name=Parameter type|param=type|desc=Specify a type for a parameter of the template documentation|type=String|status=Required}}
{{TemplateData/entry|name=Parameter status|param=status|desc=Specify a status for a parameter of the template documentation (Required, Recommended, Optional)|type=String|status=Required}}
}}
}}
</pre>


{{doc/end}}
{{doc/end}}

Revision as of 04:20, 9 December 2016

File:Template-info.svg Template Documentation

Template for creating a unified parameter format for templates

About

Creates a list that displays Template parameter in a unified format

Parameter

Do not use named parameter for 1 ... x. The first Parameter will be automatically marked as 1, the second as 2 and so on.

Parameter Description Type Status
Parameter title name

Specify a title for a parameter of the template documentation

Default:
NULL
Example:
no example
String Required
Parameter name param

Specify a name for a parameter of the template documentation

Default:
NULL
Example:
no example
String Required
Parameter alias1 alias1

Specify a alias for a parameter of the template documentation

Default:
NULL
Example:
no example
String Optional
Parameter alias2 alias2

Specify a alias for a parameter of the template documentation

Default:
NULL
Example:
no example
String Optional
Parameter alias3 alias3

Specify a alias for a parameter of the template documentation

Default:
NULL
Example:
no example
String Optional
Parameter Description desc

Specify a description for a parameter of the template documentation

Default:
no description
Example:
no example
String Recommended
Parameter Example example

Specify an example for a parameter of the template documentation

Default:
no example
Example:
no example
String Recommended
Parameter type type

Specify a type for a parameter of the template documentation

Default:
NULL
Example:
no example
String Required
Parameter status status

Specify a status for a parameter of the template documentation (Required, Recommended, Optional)

Default:
NULL
Example:
no example
String Required

See Template:TemplateData and Template:TemplateData/entry for more information about the parameter list and DDNCode for more information about types and the DDN Notation

Test of raw TemplateData output:

No description.

Template parameters

ParameterDescriptionTypeStatus
Parameter titlename

Specify a title for a parameter of the template documentation

Stringrequired
Parameter nameparam

Specify a name for a parameter of the template documentation

Stringrequired
Parameter alias1alias1

Specify a alias for a parameter of the template documentation

Stringoptional
Parameter alias2alias2

Specify a alias for a parameter of the template documentation

Stringoptional
Parameter alias3alias3

Specify a alias for a parameter of the template documentation

Stringoptional
Parameter Descriptiondesc

Specify a description for a parameter of the template documentation

Default
no description
Stringsuggested
Parameter Exampleexample

Specify an example for a parameter of the template documentation

Default
no example
Stringsuggested
Parameter typetype

Specify a type for a parameter of the template documentation

Stringrequired
Parameter statusstatus

Specify a status for a parameter of the template documentation (Required, Recommended, Optional)

Stringrequired

Examples

Complete example:

Do not use named parameter for 1 ... x. The first Parameter will be automatically marked as 1, the second as 2 and so on.

Parameter Description Type Status
Example name example param
Example alias 1
Example alias 2
Example alias 3

example description

Default:
NULL
Example:
xyz
String Required

See Template:TemplateData and Template:TemplateData/entry for more information about the parameter list and DDNCode for more information about types and the DDN Notation

Test of raw TemplateData output:

No description.

Template parameters

ParameterDescriptionTypeStatus
Example nameexample param Example alias 1 Example alias 2 Example alias 3

example description

Example
xyz
Stringrequired
{{TemplateData|
{{TemplateData/entry|name=Example name|alias1=Example alias 1|alias2=Example alias 2|alias3=Example alias 3|param=example param|desc=example description|def=NULL|example=xyz|type=String|status=Required}}
}}