Anonymous user
Module:Wikibase: Difference between revisions
Created page with "---------- Module:Wikibase ---------------- local p = {} -- Return the item ID of the item linked to the current page. function p.id(frame) if not mw.wikibase then return..."
Vivaporius (talk | contribs) m (1 revision imported) |
en>Centrist16 (Created page with "---------- Module:Wikibase ---------------- local p = {} -- Return the item ID of the item linked to the current page. function p.id(frame) if not mw.wikibase then return...") |
||
Line 7:
return "no mw.wikibase"
end
entity = mw.wikibase.getEntityObject()
Line 12 ⟶ 13:
return "no entity"
end
return entity.id
end
Line 18 ⟶ 20:
-- if no argument is provided to this method.
function p.label(frame)
end
Line 31 ⟶ 26:
-- if no argument is provided to this method.
function p.description(frame)
end
Line 47 ⟶ 35:
entity = mw.wikibase.getEntityObject()
if not entity then return nil end
id = entity.id
else
id =
end
return mw.wikibase.sitelink( id )
end
|