UNPKG

manifesto.js

Version:

IIIF Presentation API utility library for client and server

24 lines 781 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.JSONLDResource = void 0; var JSONLDResource = /** @class */ (function () { function JSONLDResource(jsonld) { this.__jsonld = jsonld; this.context = this.getProperty("context"); this.id = this.getProperty("id"); } JSONLDResource.prototype.getProperty = function (name) { var prop = null; if (this.__jsonld) { prop = this.__jsonld[name]; if (!prop) { // property may have a prepended '@' prop = this.__jsonld["@" + name]; } } return prop; }; return JSONLDResource; }()); exports.JSONLDResource = JSONLDResource; //# sourceMappingURL=JSONLDResource.js.map