@stackend/api
Version:
JS bindings to api.stackend.com
13 lines • 1.81 kB
JavaScript
"use strict";
//@flow
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
var moneyV2Query_1 = __importDefault(require("./moneyV2Query"));
var imageQuery_1 = __importDefault(require("./imageQuery"));
function fullProductQuery(imageMaxWidth, includeOriginalSrc) {
return "\n id,\n handle,\n title,\n descriptionHtml,\n updatedAt,\n createdAt,\n availableForSale,\n productType,\n tags,\n vendor,\n priceRange {\n maxVariantPrice ".concat((0, moneyV2Query_1.default)(), ",\n minVariantPrice ").concat((0, moneyV2Query_1.default)(), ",\n },\n options {\n id,\n name,\n values,\n },\n variants (first: 100) {\n edges {\n node {\n id,\n title,\n availableForSale,\n sku,\n image {\n ").concat((0, imageQuery_1.default)(imageMaxWidth, includeOriginalSrc), "\n },\n selectedOptions {\n name,\n value\n },\n price ").concat((0, moneyV2Query_1.default)(), ",\n priceV2: price ").concat((0, moneyV2Query_1.default)(), ",\n compareAtPrice ").concat((0, moneyV2Query_1.default)(), ",\n weight,\n weightUnit\n }\n }\n },\n images (first: 10, sortKey: POSITION) {\n edges {\n node {\n ").concat((0, imageQuery_1.default)(imageMaxWidth, includeOriginalSrc), "\n }\n }\n },\n collections (first: 100) {\n edges {\n node {\n handle\n }\n }\n },\n metafield__stackendAddToCartLink: metafield (namespace:\"custom\", key:\"stackend\") {\n id,\n key,\n value\n }\n");
}
exports.default = fullProductQuery;
//# sourceMappingURL=fullProductQuery.js.map