Module:Data

From MicroWiki, the micronational encyclopædia
This is an old revision of this page, as edited by KingdomOfBaustralia (talk | contribs) at 23:19, 5 June 2018. It may differ significantly from the current revision.
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Documentation for this module may be created at Module:Data/doc

local mt = {}

function mt.__index(t, k)
	return function(frame)
		local data = mw.loadData(k)
		for _,v in ipairs(frame.args) do
			data = data[v]
		end
		return data
	end
end

return setmetatable({}, mt)