UNPKG

dynamodb-toolbox

Version:

Lightweight and type-safe query builder for DynamoDB and TypeScript.

14 lines (13 loc) 609 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.isGetting = exports.$get = exports.$GET = void 0; const isObject_js_1 = require("../../../../utils/validation/isObject.js"); const isExtension_js_1 = require("./isExtension.js"); exports.$GET = Symbol('$GET'); const $get = (reference, fallback) => ({ [isExtension_js_1.$IS_EXTENSION]: true, [exports.$GET]: (fallback === undefined ? [reference] : [reference, fallback]) }); exports.$get = $get; const isGetting = (input) => (0, isObject_js_1.isObject)(input) && exports.$GET in input; exports.isGetting = isGetting;