Edge Rewrite
// HTMLRewriter · presentation

This page was redesigned at the edge.

Cloudflare fetched the original article and streamed it through HTMLRewriter to apply an entirely new visual system without rebuilding the source page.

Jump to content

Module:Sandbox/RexxS/Wd

From Wikipedia, the free encyclopedia
--[[
Demo of calling Module:Wd from another module
Licensed: CC-0
--]]

local p = {}

local wd = require("Module:Wd")

function p.rundemo(frame)
	local out = {}
	local val

	-- this is equivalent to {{wikidata|property|Q17533992|P31}}
	val = wd._property( {"Q17533992", "P31"} )
	out[#out+1] = val

	-- this is equivalent to {{wikidata|property|Q17533992|P1435}}
	val = wd._property( {"Q17533992", "P1435"} )
	out[#out+1] = val

	-- this is equivalent to {{wikidata|qualifier|Q17533992|P1435|P580}}
	val = wd._qualifier( {"Q17533992", "P1435", "P580"} )
	out[#out+1] = val

	-- this is equivalent to {{wikidata|property|qualifier|Q17533992|P1435|P580}}
	val = wd._property( {"qualifier", "Q17533992", "P1435", "P580"} )
	out[#out+1] = val

	-- this is equivalent to {{wikidata|property|reference|Q17533992|P1435}}
	val = wd._property( {"reference", "Q17533992", "P1435"} )
	out[#out+1] = val

	return "<h3> Demo </h3>" .. table.concat(out, "<br>")
end

return p