Module:Util/tables/iteratee/Documentation/Snippets: Difference between revisions

From Zelda Wiki, the Zelda encyclopedia
Jump to navigation Jump to search
(Created page with "local p = {} local util = { tables = { iteratee = require("Module:Util/tables/iteratee") } } function p.iterateeString() local games = { { abbr = "OoA", title = "Oracle of Ages" }, { title = "Bayonetta" }, } local iteratee = util.tables.iteratee("abbr") return { iteratee(games[1]), iteratee(games[2]), } end function p.iterateeTbl() end function p.iterateeFunc() end function p.iterateeNil() end return p")
 
mNo edit summary
Line 7: Line 7:
}
}


function p.iterateeString()
function p.iterateeStr()
local games = {
local games = {
{ abbr = "OoA", title = "Oracle of Ages" },
{ abbr = "OoA", title = "Oracle of Ages" },

Revision as of 21:19, 12 May 2024

Documentation for this module may be created at Module:Util/tables/iteratee/Documentation/Snippets/Documentation

local p = {}

local util = {
	tables = {
		iteratee = require("Module:Util/tables/iteratee")
	}
}

function p.iterateeStr()
	local games = {
		{ abbr = "OoA", title = "Oracle of Ages" },
		{ title = "Bayonetta" },
	}
	local iteratee = util.tables.iteratee("abbr")
	return {
		iteratee(games[1]),
		iteratee(games[2]),
	}
end

function p.iterateeTbl()
end

function p.iterateeFunc()
end

function p.iterateeNil()
end

return p