require('strict')local p =
--private_tags}}
Reads the override table in Module:Lang/data and renders a wiki table of private tags and their associated languages
local function private_tags (frame) local override_t = mw.loadData ('Module:Lang/data').override; -- get the override table local private_t = ;
for tag, lang in pairs (override_t) do if tag:find ('%-x%-') then table.insert (private_t, table.concat) end end table.sort (private_t)
table.insert (private_t, 1, '
' .. table.concat (private_t) .. '\n|}' .. ''--error (mw.dumpObject (private_t))end
--lang_xx_settings|template=}}
Reads the content of the template and extracts the parameters from for display on the template'sdocumentation page.
local function lang_xx_settings(frame) local page = mw.title.makeTitle('Template', frame.args['template'] or frame.args[1]) -- get a page object for this page in 'Template:' namespace if not page then return -- TODO: error message? end
local content = page:getContent -- get unparsed content if not page then return -- TODO: error message? end
local out =
local params local style
if content:match('}') or content:match('}') then -- if this template uses params = content:match('}') or content:match('}') -- extract the #invoke:'s parameters if not params then return -- there should be at least one or the template/module won't work TODO: error message? end table.insert(out, '
--uses_module|template=}}
Reads the content of the template to determine if this template uses Module:Lang.Returns the index of the substring '