Jump to content

Module:Module sandbox

From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by Awesome Aasim (talk | contribs) at 13:26, 12 March 2025. The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.

--- {{Module sandbox heading}}<!--
-- *				Welcome to the sandbox!				*
-- *			Please leave this part alone			*
-- *			The page is cleared regularly			*
-- *	Feel free to try your coding skills below		*
-- ■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■-->
--
-- @module sandbox
-- @alias p

local p = {}

--- Prints hello world
-- @function p.hello_world
-- @todo make it say "Hello, [name]".
-- @param {string} name Person to address
-- @return hello world string
p.hello_world = function(name)
	return "Hello world!"
end

--- Main entrypoint.
-- @function p.main
-- @param {table} frame calling frame
-- @return output wikitext
p.main = function(frame)
	local args = frame.args
	return p.hello_world(args[1] or "")
end

return p