Module:ja-def

From Wiktionary, the free dictionary
Jump to navigation Jump to search


local export = {}

local m_links = require("Module:links")
local lang = require("Module:languages").getByCode("ja")

function export.show(frame)
   	local args = require("Module:parameters").process(frame:getParent().args, {
		[1] = { required = true, list = true, allow_empty = false }
	})
	
	result = ""
	for i, v in ipairs(args[1]) do
		if result ~= "" then
			result = result .. ", "
		end
		result = result .. m_links.full_link({ term = v, lang = lang })
	end
	result = result .. ":"
	return result
end

return export