Module:Used by

require('strict') local getArgs = require("Module:Arguments").getArgs; local yesno = require("Module:Yesno");

local data = mw.loadJsonData('Module:Used by/data.json')

local p = {}

function p.flatlist(frame) local args = getArgs(frame); local title if args.title then title = mw.title.new(args.title) else title = mw.title.getCurrentTitle end local key if title.namespace == 102 then key = "extensions" else key = "skins" end local ret = "" for i, info in ipairs(data) do		if info[key][title.rootText] ~= nil then ret = ret .. "* " .. info.name if not yesno(args.nocat) and info[key .. "_cat"] ~= nil then ret = ret .. ""			end ret = ret .. "\n" end end return frame:preprocess(mw.text.trim(ret)) end

return p