Module:Sandbox/ProcrastinatingReader/Dbm: Difference between revisions

Content deleted Content added
construct
split func
Line 3:
local tWrapper = require('Module:Template wrapper')
 
local function p.buildconstructArgs(frame, args)
local tbl = {}
local current = ''
for k,v in pairs(args) do
Line 15:
end
end
return tbl
end
 
local function build(frame, args)
args = constructArgs(args)
 
local out = mw.html.create('')
for k,v in pairs(tblargs) do
out:newline():wikitext(tWrapper.wrap(frame:newChild{ title = frame:getTitle(), args = {
['_template'] = 'db-'..mw.ustring.lower(k),
Line 25 ⟶ 31:
end
 
return mw.dumpObject(tbl)out
end
 
-- Exports
 
function p.main(frame)
local args = getArgs(frame)
return p.build(frame, args)
end