Jump to content

Module:Module sandbox/doc: Difference between revisions

From Wikipedia, the free encyclopedia
Content deleted Content added
No edit summary
Tag: Reverted
No edit summary
Tag: Reverted
Line 4: Line 4:


<code><nowiki>{{</nowiki>#invoke:{{BASEPAGENAME}}{{!}}''function_name''<nowiki>}}</nowiki></code>
<code><nowiki>{{</nowiki>#invoke:{{BASEPAGENAME}}{{!}}''function_name''<nowiki>}}</nowiki></code>

== Example ==

<code><nowiki>{{</nowiki>#invoke:{{BASEPAGENAME}}{{!}}main<nowiki>}}</nowiki></code> yields:

{{#invoke:Module sandbox|main}}


|autodoc=1|infobox=0}}
|autodoc=1|infobox=0}}

Revision as of 00:42, 12 March 2025


Usage

{{#invoke:Module sandbox|function_name}}

Example

{{#invoke:Module sandbox|main}} yields:

Hello world!

Documentation

Package items

sandbox.hello_world(name) (function)
Prints hello world
Parameter: name Person to address (string)
Returns: hello world string
TODO: make it say "Hello, [name]".
sandbox.main(frame) (function)
Main entrypoint.
Parameter: frame calling frame (table)
Returns: output wikitext