Jump to content

Module:JsonLDTest

From Grigoripedia

Documentation for this module may be created at Module:JsonLDTest/doc

local p = {}

function p.test()
	if not mw.ext then
		return 'mw.ext is missing'
	end

	if not mw.ext.JsonLD then
		return 'mw.ext.JsonLD is missing'
	end

	if not mw.ext.JsonLD.addData then
		return 'mw.ext.JsonLD exists, but addData is missing'
	end

	mw.ext.JsonLD.addData({
		["identifier"] = "GRIGORIPEDIA-JSONLD-TEST"
	})

	return 'DynamicJsonLD Lua library is present'
end

return p