Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

pinelab-storefront-client

Package Overview
Dependencies
Maintainers
1
Versions
84
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

pinelab-storefront-client - npm Package Compare versions

Comparing version 0.44.2 to 0.44.3

9

lib/gridsome/gridsome.queries.js

@@ -48,11 +48,8 @@ 'use strict';

[
'\n ',
'\n {\n Vendure {\n collections {\n items {\n id\n name\n slug\n description\n parent {\n id\n name\n slug\n }\n children {\n id\n name\n slug\n }\n featuredAsset {\n preview\n thumbnail\n }\n productVariants {\n items {\n product {\n ...ProductFields\n }\n }\n }\n }\n }\n }\n }\n',
'\n {\n Vendure {\n collections {\n items {\n id\n name\n slug\n description\n parent {\n id\n name\n slug\n }\n children {\n id\n name\n slug\n }\n featuredAsset {\n preview\n thumbnail\n }\n productVariants {\n items {\n product {\n id\n name\n slug\n }\n }\n }\n }\n }\n }\n }\n',
],
[
'\n ',
'\n {\n Vendure {\n collections {\n items {\n id\n name\n slug\n description\n parent {\n id\n name\n slug\n }\n children {\n id\n name\n slug\n }\n featuredAsset {\n preview\n thumbnail\n }\n productVariants {\n items {\n product {\n ...ProductFields\n }\n }\n }\n }\n }\n }\n }\n',
'\n {\n Vendure {\n collections {\n items {\n id\n name\n slug\n description\n parent {\n id\n name\n slug\n }\n children {\n id\n name\n slug\n }\n featuredAsset {\n preview\n thumbnail\n }\n productVariants {\n items {\n product {\n id\n name\n slug\n }\n }\n }\n }\n }\n }\n }\n',
]
)),
exports.PRODUCT_FIELDS
))
);

@@ -59,0 +56,0 @@ exports.GET_AVAILABLE_COUNTRIES = graphql_request_1.gql(

@@ -7,2 +7,3 @@ import { CalculatedProduct } from '../';

Country,
Product,
ProductList,

@@ -26,3 +27,6 @@ } from '../generated/graphql';

*/
getProductsForCollection(collection: Collection): CalculatedProduct[];
getProductsForCollection(
collection: Collection,
allProducts: Product[]
): CalculatedProduct[];
getAllCollections(): Promise<CollectionList>;

@@ -29,0 +33,0 @@ getAllProducts(): Promise<ProductList>;

@@ -196,3 +196,6 @@ 'use strict';

) {
var products = _this.getProductsForCollection(collection);
var products = _this.getProductsForCollection(
collection,
productList.items
);
return {

@@ -224,8 +227,15 @@ collection: __assign(__assign({}, collection), {

*/
GridsomeService.prototype.getProductsForCollection = function (collection) {
var productsPerCollection = collection.productVariants.items.map(function (
variant
) {
return variant.product;
});
GridsomeService.prototype.getProductsForCollection = function (
collection,
allProducts
) {
var productsPerCollection = collection.productVariants.items
.map(function (variant) {
return allProducts.find(function (product) {
return product.id === variant.product.id;
});
})
.filter(function (product) {
return !!product;
});
productsPerCollection = __1.deduplicate(productsPerCollection);

@@ -232,0 +242,0 @@ return productsPerCollection.map(function (p) {

{
"name": "pinelab-storefront-client",
"version": "0.44.2",
"version": "0.44.3",
"description": "Generates static html pages with Gridsome and suplied Vue components",

@@ -50,3 +50,3 @@ "author": "Martijn van de Brug <martijn@pinelab.studio>",

},
"gitHead": "ad184e5647638a78e3e3f3de30d4d899c6db9aeb"
"gitHead": "7e2815bbd142398e8dcb0407b4188b4a741b4ff0"
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc