Module:languages/by name

ពីWiktionary

Documentation for this module may be created at Module:languages/by name/doc

local export = {}

for code, data in pairs(mw.loadData("Module:languages/data2")) do
	export[data.names[1]] = code
end

for letter in mw.ustring.gmatch("abcdefghijklmnopqrstuvwxyz", "(.)") do
	for code, data in pairs(mw.loadData("Module:languages/data3/" .. letter)) do
		export[data.names[1]] = code
	end
end

for code, data in pairs(mw.loadData("Module:languages/datax")) do
	export[data.names[1]] = code
end

return export