Module:Cookie clicker game
Documentation for this module may be created at Module:Cookie clicker game/doc
local p = {}
function p.generateHtml(frame)
local output = {}
-- Opening tags
for i = 0, frame.args[1], 1 do
table.insert(output, [[<div class="mw-collapsible mw-collapsed">]])
end
-- Numbers and closing tags
for i = frame.args[1], 0, -1 do
table.insert(output, "</div><p>")
table.insert(output, i)
table.insert(output, "</p>")
end
return table.concat(output)
end
return p