UNPKG

@webiny/api-page-builder-so-ddb

Version:

The DynamoDB storage operations Webiny Page Builder API.

42 lines (40 loc) 800 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.createPageTemplateEntity = void 0; var _toolbox = require("@webiny/db-dynamodb/toolbox"); const createPageTemplateEntity = params => { const { entityName, attributes, table } = params; return new _toolbox.Entity({ name: entityName, table, attributes: { PK: { partitionKey: true }, SK: { sortKey: true }, GSI1_PK: { type: "string" }, GSI1_SK: { type: "string" }, TYPE: { type: "string" }, data: { type: "map" }, ...(attributes || {}) } }); }; exports.createPageTemplateEntity = createPageTemplateEntity; //# sourceMappingURL=pageTemplateEntity.js.map