A modult a Modul:Lua banner/auto/doc lapon tudod dokumentálni

local p = {}

function p.auto(frame)
	return p._auto()
end

function p._auto(title)
	if title then
		title = mw.title.new(title)
	else
		title = mw.title.getCurrentTitle()
	end
	local modules = {}
	local modulesAssociative = {}
	local text = title:getContent()
	if text then
		for name in text:gmatch('{{#invoke:([^|]+)') do
			local mtitle = mw.title.makeTitle('Module', name)
			if mtitle then
				if not modulesAssociative[mtitle.prefixedText] then
					modulesAssociative[mtitle.prefixedText] = true
					table.insert(modules, mtitle.prefixedText)
				end
			end
		end
	end
	if #modules > 0 then
		return require('Module:Lua banner')._main(modules)
	else
		return nil
	end
end

return p