From fee8239d1bcf012074ae4cd71d2768d7740206f6 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Tomasz=20Anio=C5=82?=
<33483514+tom-aniol@users.noreply.github.com>
Date: Fri, 7 Dec 2018 14:45:14 +0100
Subject: [PATCH 01/42] Add Absolute Web Services Partner
---
README.md | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/README.md b/README.md
index 6b539c87d2..71c19aeffe 100644
--- a/README.md
+++ b/README.md
@@ -500,10 +500,10 @@ Vue Storefront is a Community effort brought to You by our great Core Team and s
-
+
From 87b09956009017da7e74715d233146dbc9129d74 Mon Sep 17 00:00:00 2001
From: Stian Aurdal
Date: Tue, 11 Dec 2018 22:20:05 +0100
Subject: [PATCH 02/42] fixed bug with compiling of Nofications.vue
---
src/themes/default/components/core/Notification.vue | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/themes/default/components/core/Notification.vue b/src/themes/default/components/core/Notification.vue
index 3dcf0ff63f..6f4ab10b43 100644
--- a/src/themes/default/components/core/Notification.vue
+++ b/src/themes/default/components/core/Notification.vue
@@ -4,7 +4,7 @@
Date: Wed, 12 Dec 2018 09:31:59 +0100
Subject: [PATCH 03/42] re-add nginx config in docs, update link to master
branch
---
.../nginx/sites-enabled/prod.vuestorefront.io | 62 +++++++++++++++++++
docs/guide/installation/production-setup.md | 2 +-
2 files changed, 63 insertions(+), 1 deletion(-)
create mode 100644 docs/guide/installation/etc/nginx/sites-enabled/prod.vuestorefront.io
diff --git a/docs/guide/installation/etc/nginx/sites-enabled/prod.vuestorefront.io b/docs/guide/installation/etc/nginx/sites-enabled/prod.vuestorefront.io
new file mode 100644
index 0000000000..0d1cda8d79
--- /dev/null
+++ b/docs/guide/installation/etc/nginx/sites-enabled/prod.vuestorefront.io
@@ -0,0 +1,62 @@
+server {
+ listen 80;
+ server_name prod.vuestorefront.io;
+ return 301 https://prod.vuestorefront.io$request_uri;
+}
+
+server {
+ listen 443 ssl;
+ server_name prod.vuestorefront.io http2;
+
+ ssl on;
+
+ ssl_certificate /etc/nginx/ssl/prod.vuestorefront.io.chained.crt;
+ ssl_certificate_key /etc/nginx/ssl/prod.vuestorefront.io.key;
+
+ ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
+ ssl_prefer_server_ciphers on;
+ ssl_ciphers ECDHE-RSA-AES256-GCM-SHA512:DHE-RSA-AES256-GCM-SHA512:ECDHE-RSA-AES256-GCM-SHA384:DHE-RSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-SHA384:ECDHE-RSA-AES256-SHA:DHE-RSA-AES256-SHA;
+ ssl_ecdh_curve secp384r1;
+ ssl_session_timeout 10m;
+ ssl_session_cache shared:SSL:10m;
+ ssl_session_tickets off;
+ ssl_stapling on;
+ ssl_stapling_verify on;
+ resolver 8.8.8.8 8.8.4.4 valid=300s;
+ resolver_timeout 5s;
+
+ ssl_dhparam /etc/nginx/ssl/dhparam.pem;
+
+ add_header Strict-Transport-Security "max-age=31536000" always;
+ add_header X-Frame-Options DENY;
+ add_header X-Content-Type-Options nosniff;
+ add_header X-XSS-Protection "1; mode=block";
+ add_header X-Robots-Tag none;
+
+ gzip on;
+ gzip_proxied any;
+ gzip_types
+ text/css
+ text/javascript
+ text/xml
+ application/javascript
+ application/json
+ text/json
+ text/html;
+
+ location / {
+ proxy_pass http://localhost:3000/;
+ }
+
+ location /assets/ {
+ proxy_pass http://localhost:3000/assets/;
+ }
+
+ location /api/ {
+ proxy_pass http://localhost:8080/api/;
+ }
+
+ location /img/ {
+ proxy_pass http://localhost:8080/img/;
+ }
+}
diff --git a/docs/guide/installation/production-setup.md b/docs/guide/installation/production-setup.md
index ba14eec3d6..16c0bd5354 100644
--- a/docs/guide/installation/production-setup.md
+++ b/docs/guide/installation/production-setup.md
@@ -70,7 +70,7 @@ Some additional materials:
#### Nginx configuration
-[Here is the complete `/etc/nginx/sites-enabled/prod.vuestorefront.io` file](https://github.com/DivanteLtd/vue-storefront/tree/develop/doc/production-setup/etc/nginx/sites-enabled).
+[Here is the complete `/etc/nginx/sites-enabled/prod.vuestorefront.io` file](https://github.com/DivanteLtd/vue-storefront/tree//master/docs/guide/installation/etc/nginx/sites-enabled/prod.vuestorefront.io).
Create nginx config file from the template (please run as a root user):
From 43c66057903a216de3841bf1452a588e8e1c3dad Mon Sep 17 00:00:00 2001
From: Jan Myszkier
Date: Wed, 12 Dec 2018 09:34:24 +0100
Subject: [PATCH 04/42] fix double slash in github link
---
docs/guide/installation/production-setup.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/guide/installation/production-setup.md b/docs/guide/installation/production-setup.md
index 16c0bd5354..4974c9fa63 100644
--- a/docs/guide/installation/production-setup.md
+++ b/docs/guide/installation/production-setup.md
@@ -70,7 +70,7 @@ Some additional materials:
#### Nginx configuration
-[Here is the complete `/etc/nginx/sites-enabled/prod.vuestorefront.io` file](https://github.com/DivanteLtd/vue-storefront/tree//master/docs/guide/installation/etc/nginx/sites-enabled/prod.vuestorefront.io).
+[Here is the complete `/etc/nginx/sites-enabled/prod.vuestorefront.io` file](https://github.com/DivanteLtd/vue-storefront/tree/master/docs/guide/installation/etc/nginx/sites-enabled/prod.vuestorefront.io).
Create nginx config file from the template (please run as a root user):
From 011ab7712b162b564efab8bfc96eb4a343b67b72 Mon Sep 17 00:00:00 2001
From: Piotr Karwatka
Date: Wed, 12 Dec 2018 15:30:50 +0100
Subject: [PATCH 05/42] Update README.md
---
README.md | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 71c19aeffe..baba1791ad 100644
--- a/README.md
+++ b/README.md
@@ -8,7 +8,7 @@


-Vue Storefront is a standalone PWA storefront for your eCommerce, possible to connect with any eCommerce backend (eg. Magento, Pimcore/CoreShop, Prestashop or Shopware) through the API.
+Vue Storefront is a standalone PWA storefront for your eCommerce, possible to connect with any eCommerce backend (eg. Magento, Pimcore/CoreShop, [BigCommerce](https://github.com/DivanteLtd/bigcommerce2vuestorefront), Prestashop or Shopware) through the API.
Vue Storefront is and always will be in the open source. Anyone can use and support the project, we want it to be a tool for the improvement of the shopping experience.
The project is in the **production ready** phase.
@@ -131,7 +131,8 @@ Tutorial series on creating themes for Vue Storefront:
- [Vue Storefront + Magento](https://github.com/DivanteLtd/mage2vuestorefront)
- [Vue Storefront + Magento 1.9](https://github.com/DivanteLtd/magento1-vsbridge)
- [Vue Storefront + with Magento checkout](https://github.com/DivanteLtd/magento2-external-checkout)
-- [Vue Storefront + Pimcore](https://github.com/DivanteLtd/pimcore2vuestorefront)
+- [Vue Storefront + BigCommerce](https://github.com/DivanteLtd/bigcommerce2vuestorefront)
+- [Vue Storefront + Pimcore](https://github.com/DivanteLtd/coreshop-vsbridge)
- [Magento2 Product Reviews](https://divanteltd.github.io/vue-storefront/guide/integrations/reviews.html)
- [PayPal Payments integration](https://divanteltd.github.io/vue-storefront/guide/integrations/paypal-payments.html)
- [Direct prices sync with Magento](https://divanteltd.github.io/vue-storefront/guide/integrations/direct-prices-sync.html)
From 95e20e0113bc7d6b509f1960e6c75d12b4a6c93d Mon Sep 17 00:00:00 2001
From: PX-FE1 VS
Date: Thu, 13 Dec 2018 00:49:26 +0200
Subject: [PATCH 06/42] fixed bug with toggle wishlist
---
src/modules/ui-store/index.ts | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/modules/ui-store/index.ts b/src/modules/ui-store/index.ts
index 9bf42217e0..09840206e0 100644
--- a/src/modules/ui-store/index.ts
+++ b/src/modules/ui-store/index.ts
@@ -68,7 +68,7 @@ const store = {
commit('setMicrocart', !state.microcart)
},
toggleWishlist ({ commit, state }) {
- commit('setWishlist', !state.microcart)
+ commit('setWishlist', !state.wishlist)
}
}
}
From c813b26b9a80d496fd8b64c0ef5252e229c97ed4 Mon Sep 17 00:00:00 2001
From: Agata Firlejczyk
Date: Tue, 18 Dec 2018 10:25:01 +0100
Subject: [PATCH 07/42] findConfigurableChildAsync - fix checking stock for
configurable child
---
core/modules/catalog/helpers/index.ts | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/core/modules/catalog/helpers/index.ts b/core/modules/catalog/helpers/index.ts
index 4309fdc3b8..c9a0580923 100644
--- a/core/modules/catalog/helpers/index.ts
+++ b/core/modules/catalog/helpers/index.ts
@@ -356,7 +356,7 @@ export function populateProductConfigurationAsync (context, { product, selectedV
for (let option of product.configurable_options) {
let attribute_code
let attribute_label
- if (option.attribute_id) {
+ if (option.attribute_id) {
let attr = context.rootState.attribute.list_by_id[option.attribute_id]
if (!attr) {
console.error('Wrong attribute given in configurable_options - can not find by attribute_id', option)
@@ -368,7 +368,7 @@ export function populateProductConfigurationAsync (context, { product, selectedV
} else {
if (!option.attribute_code) {
console.error('Wrong attribute given in configurable_options - no attribute_code', option)
- continue
+ continue
} else { // we do have attribute_code!
attribute_code = option.attribute_code
attribute_label = option.frontend_label ? option.frontend_label : option.default_frontend_label
@@ -419,7 +419,7 @@ export function findConfigurableChildAsync({ product, configuration = null, sele
if (availabilityCheck) {
if (configurableChild.stock && !rootStore.state.config.products.listOutOfStockProducts) {
- if (!configurableChild.is_in_stock) {
+ if (!configurableChild.stock.is_in_stock) {
return false
}
}
@@ -511,7 +511,7 @@ export function configureProductAsync (context, { product, configuration, select
if (selectDefaultVariant) {
context.dispatch('setCurrent', product) // without the configuration
}
- }
+ }
return selectedVariant
} else {
if (fallbackToDefaultWhenNoAvailable) {
From dd524b12bceeb53d07af3324d90b9c5736f84850 Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Sun, 23 Dec 2018 18:35:23 +0100
Subject: [PATCH 08/42] Update README.md
---
README.md | 12 +++++++++++-
1 file changed, 11 insertions(+), 1 deletion(-)
diff --git a/README.md b/README.md
index baba1791ad..0802b941e1 100644
--- a/README.md
+++ b/README.md
@@ -66,9 +66,19 @@ Yes! There are more than 10 implementations happening right now and many live sh
If you have any questions or ideas feel free to join our slack: https://vuestorefront.slack.com via [invitation link](https://join.slack.com/t/vuestorefront/shared_invite/enQtMzA4MTM2NTE5NjM2LTI1M2RmOWIyOTk0MzFlMDU3YzJlYzcyYzNiNjUyZWJiMTZjZjc3MjRlYmE5ZWQ1YWRhNTQyM2ZjN2ZkMzZlNTg)
## Roadmap
+[Here](https://github.com/DivanteLtd/vue-storefront/projects/3) you can vote for feature requests. The most popular ones will be added to next milestones.
+The process of adding new features to the roadmap looks like this:
+1. You create an issue and label it as `feature request`.
+2. One of VS Core team verifies the feature request and if the explaination is clear adds it to the `Roadmap` project so it's visible in the baord.
+3. Now people can vote for this feature to be added into next milestone with t`humb up` emoji.
+4. Feature requests with biggest popularity will be added into next milestones.
We are planning 1-2 milestones ahead. Our milestones are based on requirements from community, partners and production implementations.
-[See the roadmap](https://github.com/DivanteLtd/vue-storefront/milestones).
+
+Please note that bugfixes are treated separately and in most cases added to the milestones immediately.
+
+[Here](https://github.com/DivanteLtd/vue-storefront/milestones) you can see how new features and improvements are ditributed in milestones. Each milestone is one release and takes one month.
+
[Check the feature list of 1.0](https://divanteltd.github.io/vue-storefront/guide/basics/feature-list.html).
If youd like to take part in roadmap planning feel free to join #roadmap-planning channel on our slack
From 8ae4a27cc52fe1843d056d9198ce08d40fc2c321 Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Sun, 23 Dec 2018 18:38:27 +0100
Subject: [PATCH 09/42] Update README.md
---
README.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/README.md b/README.md
index 0802b941e1..91b0de105f 100644
--- a/README.md
+++ b/README.md
@@ -66,7 +66,7 @@ Yes! There are more than 10 implementations happening right now and many live sh
If you have any questions or ideas feel free to join our slack: https://vuestorefront.slack.com via [invitation link](https://join.slack.com/t/vuestorefront/shared_invite/enQtMzA4MTM2NTE5NjM2LTI1M2RmOWIyOTk0MzFlMDU3YzJlYzcyYzNiNjUyZWJiMTZjZjc3MjRlYmE5ZWQ1YWRhNTQyM2ZjN2ZkMzZlNTg)
## Roadmap
-[Here](https://github.com/DivanteLtd/vue-storefront/projects/3) you can vote for feature requests. The most popular ones will be added to next milestones.
+[Here](https://github.com/DivanteLtd/vue-storefront/projects/3) you can vote for feature requests and see which ones were accepted. The most popular ones will be added to next milestones.
The process of adding new features to the roadmap looks like this:
1. You create an issue and label it as `feature request`.
2. One of VS Core team verifies the feature request and if the explaination is clear adds it to the `Roadmap` project so it's visible in the baord.
@@ -77,7 +77,7 @@ We are planning 1-2 milestones ahead. Our milestones are based on requirements f
Please note that bugfixes are treated separately and in most cases added to the milestones immediately.
-[Here](https://github.com/DivanteLtd/vue-storefront/milestones) you can see how new features and improvements are ditributed in milestones. Each milestone is one release and takes one month.
+[Here](https://github.com/DivanteLtd/vue-storefront/milestones) you can find the accepted roadmap for current milestone and what you can expect with next release.
[Check the feature list of 1.0](https://divanteltd.github.io/vue-storefront/guide/basics/feature-list.html).
From ad2d0c68487ad7735cbc5810d8ad6447e1b7d023 Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 24 Dec 2018 10:37:33 +0100
Subject: [PATCH 10/42] Update README.md
---
README.md | 13 +++++++++----
1 file changed, 9 insertions(+), 4 deletions(-)
diff --git a/README.md b/README.md
index 91b0de105f..9e754aa3c3 100644
--- a/README.md
+++ b/README.md
@@ -66,18 +66,23 @@ Yes! There are more than 10 implementations happening right now and many live sh
If you have any questions or ideas feel free to join our slack: https://vuestorefront.slack.com via [invitation link](https://join.slack.com/t/vuestorefront/shared_invite/enQtMzA4MTM2NTE5NjM2LTI1M2RmOWIyOTk0MzFlMDU3YzJlYzcyYzNiNjUyZWJiMTZjZjc3MjRlYmE5ZWQ1YWRhNTQyM2ZjN2ZkMzZlNTg)
## Roadmap
-[Here](https://github.com/DivanteLtd/vue-storefront/projects/3) you can vote for feature requests and see which ones were accepted. The most popular ones will be added to next milestones.
+
+[Here](https://github.com/DivanteLtd/vue-storefront/milestones) you can find the accepted roadmap for current milestone and what you can expect with next release.
+
+#### Roadmap planning
+[Here](https://github.com/DivanteLtd/vue-storefront/projects/3) you can vote for feature requests and see which ones were accepted. The most upvoted ones will be added to next milestones. You can also joj slack channel `#roadmap-planning` where we discuss next milestones.
+
The process of adding new features to the roadmap looks like this:
1. You create an issue and label it as `feature request`.
-2. One of VS Core team verifies the feature request and if the explaination is clear adds it to the `Roadmap` project so it's visible in the baord.
-3. Now people can vote for this feature to be added into next milestone with t`humb up` emoji.
+2. One of VS Core team verifies the feature request and if the explaination is clear adds it to the `Roadmap` project so it's visible in the board.
+3. Now people can vote for this feature to be added into next milestone with `thumb up` emoji.
4. Feature requests with biggest popularity will be added into next milestones.
We are planning 1-2 milestones ahead. Our milestones are based on requirements from community, partners and production implementations.
Please note that bugfixes are treated separately and in most cases added to the milestones immediately.
-[Here](https://github.com/DivanteLtd/vue-storefront/milestones) you can find the accepted roadmap for current milestone and what you can expect with next release.
+
[Check the feature list of 1.0](https://divanteltd.github.io/vue-storefront/guide/basics/feature-list.html).
From fc1590105ef9c3b53b5c0ebef4ea0f8ba029ad0a Mon Sep 17 00:00:00 2001
From: Anton Lobodenko
Date: Thu, 27 Dec 2018 17:18:30 +0200
Subject: [PATCH 11/42] Fix user logout (clear wishlist and checkout user
fields)
---
core/modules/user/store/actions.ts | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/core/modules/user/store/actions.ts b/core/modules/user/store/actions.ts
index bf92d77e9a..efffe0bce1 100644
--- a/core/modules/user/store/actions.ts
+++ b/core/modules/user/store/actions.ts
@@ -297,6 +297,10 @@ const actions: ActionTree = {
context.commit(types.USER_GROUP_TOKEN_CHANGED, '')
context.commit(types.USER_GROUP_CHANGED, null)
context.commit(types.USER_INFO_LOADED, null)
+ context.dispatch('wishlist/clear', null, {root: true})
+ context.dispatch('checkout/savePersonalDetails', {}, {root: true})
+ context.dispatch('checkout/saveShippingDetails', {}, {root: true})
+ context.dispatch('checkout/savePaymentDetails', {}, {root: true})
},
/**
* Logout user
@@ -316,7 +320,7 @@ const actions: ActionTree = {
}
const usersCollection = Vue.prototype.$db.usersCollection
usersCollection.setItem('current-token', '')
-
+
if (rootStore.state.route.path === '/my-account') {
// router.push('/')
}
From 92681195ef8c4c63b08fd2a0a4dfe71a9bbe6d69 Mon Sep 17 00:00:00 2001
From: Jan Myszkier
Date: Thu, 3 Jan 2019 10:23:36 +0100
Subject: [PATCH 12/42] Update production-setup.md
Fix develop config paths
---
docs/guide/installation/production-setup.md | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/docs/guide/installation/production-setup.md b/docs/guide/installation/production-setup.md
index 4974c9fa63..73f7d79422 100644
--- a/docs/guide/installation/production-setup.md
+++ b/docs/guide/installation/production-setup.md
@@ -250,18 +250,18 @@ It may take a few minutes. Once the modules are installed we can set configurati
#### Vue Storefront configuration
-The full configuration files are available here to download: [vue-storefront](https://github.com/DivanteLtd/vue-storefront/tree/develop/doc/production-setup/vue-storefront/config) and [vue-storefront-api](https://github.com/DivanteLtd/vue-storefront/tree/develop/doc/production-setup/vue-storefront-api/config).
+The full configuration files are available here to download: [vue-storefront](https://github.com/DivanteLtd/vue-storefront/blob/develop/docs/guide/installation/vue-storefront/config) and [vue-storefront-api](https://github.com/DivanteLtd/vue-storefront/blob/develop/docs/guide/installation/vue-storefront-api/config).
Please create the `vue-storefront-api/config/local.json` and `vue-storefront/config/local.json` files accordingly.
```bash
-curl https://raw.githubusercontent.com/DivanteLtd/vue-storefront/develop/doc/production-setup/vue-storefront-api/config/local.json > /home/www/vuestorefront/vue-storefront-api/config/local.json
+curl https://github.com/DivanteLtd/vue-storefront/blob/develop/docs/guide/installation/vue-storefront-api/config/local.json > /home/www/vuestorefront/vue-storefront-api/config/local.json
```
... and ...
```bash
-curl https://raw.githubusercontent.com/DivanteLtd/vue-storefront/develop/doc/production-setup/vue-storefront/config/local.json > /home/www/vuestorefront/vue-storefront/config/local.json
+curl https://github.com/DivanteLtd/vue-storefront/blob/develop/docs/guide/installation/vue-storefront/config/local.json > /home/www/vuestorefront/vue-storefront/config/local.json
```
Please find the key sections of the `vue-storefront/config/local.json` file described in below:
@@ -321,7 +321,7 @@ There are 27 more instances of `prod.vuestorefront.io` to be replaced with your
#### Vue Storefront API configuration
-The [provided vue-storefront-api configuration](https://github.com/DivanteLtd/vue-storefront/tree/develop/doc/production-setup/vue-storefront-api/config) requires almost no changes.
+The [provided vue-storefront-api configuration](https://github.com/DivanteLtd/vue-storefront/blob/develop/docs/guide/installation/vue-storefront-api/config) requires almost no changes.
The only lines you need to alter are:
From cc0ce3c4b87ceac927f57c284493873cfbe1dd7f Mon Sep 17 00:00:00 2001
From: Jan Myszkier
Date: Thu, 3 Jan 2019 10:41:30 +0100
Subject: [PATCH 13/42] Update production-setup.md
Add description on how to configure existing magento2 instance and get API keys for vue-storefront-api
---
docs/guide/installation/production-setup.md | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/docs/guide/installation/production-setup.md b/docs/guide/installation/production-setup.md
index 73f7d79422..545c5008bf 100644
--- a/docs/guide/installation/production-setup.md
+++ b/docs/guide/installation/production-setup.md
@@ -362,6 +362,13 @@ The only lines you need to alter are:
You should put here the `allowedHosts` and `trustedHosts` for the Imageable - to download the product images. The domain name points to the **Magento2** instance where images are sourced. In this example Magento2 is running under **http://demo-magento2.vuestorefront.io**.
+ #### Using your own magento2 instance
+ In this case you'll have to update `magento2` config node with correct hostname in vue-storefront-api config file. To get all necessary Magento2 API data for `api` node, navigate to SYSTEM -> Extensions -> Integrations in Magento2 Admin.
+ - click Add new integration
+ - check the necessary permissions (check Catalog, Sales, My Account and Carts on API permissions tab )
+ - click Activate
+ - copy necessary keys, secrets and tokens into `api` section of vue-storefront-api config
+
#### Build VS
Before we can run Vue Storefront and Vue Storefront API we should build it in the production mode. To do so please just execute the following commands:
From 9ca5081f107d92441c6043f378b91e1bce87a93c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Tomasz=20Anio=C5=82?=
<33483514+tom-aniol@users.noreply.github.com>
Date: Fri, 4 Jan 2019 13:02:44 +0100
Subject: [PATCH 14/42] Add DevMe Tokyo in Readme
---
README.md | 47 +++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 47 insertions(+)
diff --git a/README.md b/README.md
index 9e754aa3c3..32ec9a7dd4 100644
--- a/README.md
+++ b/README.md
@@ -525,6 +525,53 @@ Vue Storefront is a Community effort brought to You by our great Core Team and s
|
+
+
+
+
+
+ |
+
+
+
+
+ |
+
+
+
+
+ |
+
+
+
+
+ |
+
+
+
+
+ |
+
From 1304eec5c730335c5363dab51b0bba187fcdd62c Mon Sep 17 00:00:00 2001
From: patzick
Date: Sun, 6 Jan 2019 18:41:20 +0100
Subject: [PATCH 15/42] fix multiple placing order invocation after changing
payment methods
---
.../hooks/afterRegistration.ts | 15 +-
yarn.lock | 216 +-----------------
2 files changed, 19 insertions(+), 212 deletions(-)
diff --git a/src/modules/payment-backend-methods/hooks/afterRegistration.ts b/src/modules/payment-backend-methods/hooks/afterRegistration.ts
index 1ba3d863da..38aac0de11 100644
--- a/src/modules/payment-backend-methods/hooks/afterRegistration.ts
+++ b/src/modules/payment-backend-methods/hooks/afterRegistration.ts
@@ -1,9 +1,14 @@
import * as types from './../store/mutation-types'
export function afterRegistration(Vue, config, store, isServer) {
+
+ let correctPaymentMethod = false
+
// Place the order. Payload is empty as we don't have any specific info to add for this payment method '{}'
const placeOrder = function () {
- Vue.prototype.$bus.$emit('checkout-do-placeOrder', {})
+ if (correctPaymentMethod) {
+ Vue.prototype.$bus.$emit('checkout-do-placeOrder', {})
+ }
}
if (!Vue.prototype.$isServer) {
@@ -12,15 +17,15 @@ export function afterRegistration(Vue, config, store, isServer) {
store.commit('payment-backend-methods/' + types.SET_BACKEND_PAYMENT_METHODS, methods)
})
+ Vue.prototype.$bus.$on('checkout-before-placeOrder', placeOrder)
+
// Mount the info component when required.
Vue.prototype.$bus.$on('checkout-payment-method-changed', (paymentMethodCode) => {
let methods = store.state['payment-backend-methods'].methods
if (methods !== null && methods.find(item => item.code === paymentMethodCode)) {
- // Register the handler for what happens when they click the place order button.
- Vue.prototype.$bus.$on('checkout-before-placeOrder', placeOrder)
+ correctPaymentMethod = true
} else {
- // unregister the extensions placeorder handler
- Vue.prototype.$bus.$off('checkout-before-placeOrder', placeOrder)
+ correctPaymentMethod = false
}
})
}
diff --git a/yarn.lock b/yarn.lock
index 9d522e419e..5169f2e4e9 100644
--- a/yarn.lock
+++ b/yarn.lock
@@ -1203,7 +1203,7 @@ ansi-styles@^2.1.0, ansi-styles@^2.2.1:
version "2.2.1"
resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-2.2.1.tgz#b432dd3358b634cf75e1e4664368240533c1ddbe"
-ansi-styles@^3.1.0, ansi-styles@^3.2.1:
+ansi-styles@^3.2.1:
version "3.2.1"
resolved "https://registry.yarnpkg.com/ansi-styles/-/ansi-styles-3.2.1.tgz#41fbb20243e50b12be0f04b8dedbf07520ce841d"
dependencies:
@@ -1484,19 +1484,6 @@ aws4@^1.6.0, aws4@^1.8.0:
version "1.8.0"
resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.8.0.tgz#f0e003d9ca9e7f59c7a508945d7b2ef9a04a542f"
-axios@0.15.3:
- version "0.15.3"
- resolved "http://registry.npmjs.org/axios/-/axios-0.15.3.tgz#2c9d638b2e191a08ea1d6cc988eadd6ba5bdc053"
- dependencies:
- follow-redirects "1.0.0"
-
-axios@^0.17.0:
- version "0.17.1"
- resolved "https://registry.yarnpkg.com/axios/-/axios-0.17.1.tgz#2d8e3e5d0bdbd7327f91bc814f5c57660f81824d"
- dependencies:
- follow-redirects "^1.2.5"
- is-buffer "^1.1.5"
-
babel-code-frame@^6.22.0, babel-code-frame@^6.26.0:
version "6.26.0"
resolved "https://registry.yarnpkg.com/babel-code-frame/-/babel-code-frame-6.26.0.tgz#63fd43f7dc1e3bb7ce35947db8fe369a3f58c74b"
@@ -2168,13 +2155,6 @@ binary-extensions@^1.0.0:
version "1.12.0"
resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-1.12.0.tgz#c2d780f53d45bba8317a8902d4ceeaf3a6385b14"
-bl@^1.0.0:
- version "1.2.2"
- resolved "http://registry.npmjs.org/bl/-/bl-1.2.2.tgz#a160911717103c07410cef63ef51b397c025af9c"
- dependencies:
- readable-stream "^2.3.5"
- safe-buffer "^5.1.1"
-
blessed@^0.1.81:
version "0.1.81"
resolved "https://registry.yarnpkg.com/blessed/-/blessed-0.1.81.tgz#f962d687ec2c369570ae71af843256e6d0ca1129"
@@ -2278,13 +2258,6 @@ brorand@^1.0.1:
version "1.1.0"
resolved "https://registry.yarnpkg.com/brorand/-/brorand-1.1.0.tgz#12c25efe40a45e3c323eb8675a0a0ce57b22371f"
-brotli-size@0.0.1:
- version "0.0.1"
- resolved "https://registry.yarnpkg.com/brotli-size/-/brotli-size-0.0.1.tgz#8c1aeea01cd22f359b048951185bd539ff0c829f"
- dependencies:
- duplexer "^0.1.1"
- iltorb "^1.0.9"
-
browser-stdout@1.3.1:
version "1.3.1"
resolved "https://registry.yarnpkg.com/browser-stdout/-/browser-stdout-1.3.1.tgz#baa559ee14ced73452229bad7326467c61fabd60"
@@ -2399,26 +2372,11 @@ builtin-status-codes@^3.0.0:
version "3.0.0"
resolved "https://registry.yarnpkg.com/builtin-status-codes/-/builtin-status-codes-3.0.0.tgz#85982878e21b98e1c66425e03d0174788f569ee8"
-bundlesize@^0.17.0:
- version "0.17.0"
- resolved "https://registry.yarnpkg.com/bundlesize/-/bundlesize-0.17.0.tgz#212ae5731ab0554d2acd509d23e1de18640b2008"
- dependencies:
- axios "^0.17.0"
- brotli-size "0.0.1"
- bytes "^3.0.0"
- ci-env "^1.4.0"
- commander "^2.11.0"
- github-build "^1.2.0"
- glob "^7.1.2"
- gzip-size "^4.0.0"
- prettycli "^1.4.3"
- read-pkg-up "^3.0.0"
-
byline@^5.0.0:
version "5.0.0"
resolved "https://registry.yarnpkg.com/byline/-/byline-5.0.0.tgz#741c5216468eadc457b03410118ad77de8c1ddb1"
-bytes@3.0.0, bytes@^3.0.0:
+bytes@3.0.0:
version "3.0.0"
resolved "https://registry.yarnpkg.com/bytes/-/bytes-3.0.0.tgz#d32815404d689699f85a4ea4fa8755dd13a96048"
@@ -2617,14 +2575,6 @@ chalk@1.1.1:
strip-ansi "^3.0.0"
supports-color "^2.0.0"
-chalk@2.1.0:
- version "2.1.0"
- resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.1.0.tgz#ac5becf14fa21b99c6c92ca7a7d7cfd5b17e743e"
- dependencies:
- ansi-styles "^3.1.0"
- escape-string-regexp "^1.0.5"
- supports-color "^4.0.0"
-
chalk@2.4.1, chalk@^2.0.0, chalk@^2.0.1, chalk@^2.1.0, chalk@^2.3.0, chalk@^2.3.2, chalk@^2.4.1:
version "2.4.1"
resolved "https://registry.yarnpkg.com/chalk/-/chalk-2.4.1.tgz#18c49ab16a037b6eb0152cc83e3471338215b66e"
@@ -2692,10 +2642,6 @@ chrome-trace-event@^1.0.0:
dependencies:
tslib "^1.9.0"
-ci-env@^1.4.0:
- version "1.7.0"
- resolved "https://registry.yarnpkg.com/ci-env/-/ci-env-1.7.0.tgz#55cc9f8ff7bb4380de298cbed3ae27c35dcdfd8e"
-
ci-info@^1.0.0, ci-info@^1.5.0:
version "1.6.0"
resolved "https://registry.yarnpkg.com/ci-info/-/ci-info-1.6.0.tgz#2ca20dbb9ceb32d4524a683303313f0304b1e497"
@@ -2928,7 +2874,7 @@ command-join@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/command-join/-/command-join-2.0.0.tgz#52e8b984f4872d952ff1bdc8b98397d27c7144cf"
-commander@2, commander@^2.11.0, commander@^2.15.1, commander@^2.18.0:
+commander@2, commander@^2.15.1, commander@^2.18.0:
version "2.19.0"
resolved "https://registry.yarnpkg.com/commander/-/commander-2.19.0.tgz#f6198aa84e5b83c46054b94ddedbfed5ee9ff12a"
@@ -3662,12 +3608,6 @@ decode-uri-component@^0.2.0:
version "0.2.0"
resolved "https://registry.yarnpkg.com/decode-uri-component/-/decode-uri-component-0.2.0.tgz#eb3913333458775cb84cd1a1fae062106bb87545"
-decompress-response@^3.3.0:
- version "3.3.0"
- resolved "https://registry.yarnpkg.com/decompress-response/-/decompress-response-3.3.0.tgz#80a4dd323748384bfa248083622aedec982adff3"
- dependencies:
- mimic-response "^1.0.0"
-
dedent@^0.7.0:
version "0.7.0"
resolved "https://registry.yarnpkg.com/dedent/-/dedent-0.7.0.tgz#2495ddbaf6eb874abb0e1be9df22d2e5a544326c"
@@ -3797,11 +3737,7 @@ detect-installed@^2.0.4:
dependencies:
get-installed-path "^2.0.3"
-detect-libc@^0.2.0:
- version "0.2.0"
- resolved "https://registry.yarnpkg.com/detect-libc/-/detect-libc-0.2.0.tgz#47fdf567348a17ec25fcbf0b9e446348a76f9fb5"
-
-detect-libc@^1.0.2, detect-libc@^1.0.3:
+detect-libc@^1.0.2:
version "1.0.3"
resolved "https://registry.yarnpkg.com/detect-libc/-/detect-libc-1.0.3.tgz#fa137c4bd698edf55cd5cd02ac559f91a4c4ba9b"
@@ -4449,10 +4385,6 @@ expand-range@^1.8.1:
dependencies:
fill-range "^2.1.0"
-expand-template@^1.0.2:
- version "1.1.1"
- resolved "https://registry.yarnpkg.com/expand-template/-/expand-template-1.1.1.tgz#981f188c0c3a87d2e28f559bc541426ff94f21dd"
-
expand-tilde@^2.0.0, expand-tilde@^2.0.2:
version "2.0.2"
resolved "https://registry.yarnpkg.com/expand-tilde/-/expand-tilde-2.0.2.tgz#97e801aa052df02454de46b02bf621642cdc8502"
@@ -4762,13 +4694,7 @@ flush-write-stream@^1.0.0:
inherits "^2.0.1"
readable-stream "^2.0.4"
-follow-redirects@1.0.0:
- version "1.0.0"
- resolved "http://registry.npmjs.org/follow-redirects/-/follow-redirects-1.0.0.tgz#8e34298cbd2e176f254effec75a1c78cc849fd37"
- dependencies:
- debug "^2.2.0"
-
-follow-redirects@^1.0.0, follow-redirects@^1.2.5:
+follow-redirects@^1.0.0:
version "1.5.10"
resolved "https://registry.yarnpkg.com/follow-redirects/-/follow-redirects-1.5.10.tgz#7b7a9f9aea2fdff36786a94ff643ed07f4ff5e2a"
dependencies:
@@ -4837,10 +4763,6 @@ fs-access@^1.0.0:
dependencies:
null-check "^1.0.0"
-fs-constants@^1.0.0:
- version "1.0.0"
- resolved "https://registry.yarnpkg.com/fs-constants/-/fs-constants-1.0.0.tgz#6be0de9be998ce16af8afc24497b9ee9b7ccd9ad"
-
fs-exists-sync@^0.1.0:
version "0.1.0"
resolved "https://registry.yarnpkg.com/fs-exists-sync/-/fs-exists-sync-0.1.0.tgz#982d6893af918e72d08dec9e8673ff2b5a8d6add"
@@ -5025,16 +4947,6 @@ gitconfiglocal@^1.0.0:
dependencies:
ini "^1.3.2"
-github-build@^1.2.0:
- version "1.2.0"
- resolved "https://registry.yarnpkg.com/github-build/-/github-build-1.2.0.tgz#b0bdb705ae4088218577e863c1a301030211051f"
- dependencies:
- axios "0.15.3"
-
-github-from-package@0.0.0:
- version "0.0.0"
- resolved "https://registry.yarnpkg.com/github-from-package/-/github-from-package-0.0.0.tgz#97fb5d96bfde8973313f20e8288ef9a167fa64ce"
-
"gkt@https://tgz.pm2.io/gkt-1.0.0.tgz":
version "1.0.0"
resolved "https://tgz.pm2.io/gkt-1.0.0.tgz#405502b007f319c3f47175c4474527300f2ab5ad"
@@ -5229,13 +5141,6 @@ growl@1.10.5:
version "1.10.5"
resolved "https://registry.yarnpkg.com/growl/-/growl-1.10.5.tgz#f2735dc2283674fa67478b10181059355c369e5e"
-gzip-size@^4.0.0:
- version "4.1.0"
- resolved "https://registry.yarnpkg.com/gzip-size/-/gzip-size-4.1.0.tgz#8ae096257eabe7d69c45be2b67c448124ffb517c"
- dependencies:
- duplexer "^0.1.1"
- pify "^3.0.0"
-
gzip-size@^5.0.0:
version "5.0.0"
resolved "https://registry.yarnpkg.com/gzip-size/-/gzip-size-5.0.0.tgz#a55ecd99222f4c48fd8c01c625ce3b349d0a0e80"
@@ -5544,15 +5449,6 @@ ignore@^3.3.3, ignore@^3.3.5, ignore@^3.3.6:
version "3.3.10"
resolved "https://registry.yarnpkg.com/ignore/-/ignore-3.3.10.tgz#0a97fb876986e8081c631160f8f9f389157f0043"
-iltorb@^1.0.9:
- version "1.3.10"
- resolved "https://registry.yarnpkg.com/iltorb/-/iltorb-1.3.10.tgz#a0d9e4e7d52bf510741442236cbe0cc4230fc9f8"
- dependencies:
- detect-libc "^0.2.0"
- nan "^2.6.2"
- node-gyp "^3.6.2"
- prebuild-install "^2.3.0"
-
immediate@^3.2.3:
version "3.2.3"
resolved "https://registry.yarnpkg.com/immediate/-/immediate-3.2.3.tgz#d140fa8f614659bd6541233097ddaac25cdd991c"
@@ -7035,10 +6931,6 @@ mimic-fn@^1.0.0:
version "1.2.0"
resolved "https://registry.yarnpkg.com/mimic-fn/-/mimic-fn-1.2.0.tgz#820c86a39334640e99516928bd03fca88057d022"
-mimic-response@^1.0.0:
- version "1.0.1"
- resolved "https://registry.yarnpkg.com/mimic-response/-/mimic-response-1.0.1.tgz#4923538878eef42063cb8a3e3b0798781487ab1b"
-
min-document@^2.19.0:
version "2.19.0"
resolved "https://registry.yarnpkg.com/min-document/-/min-document-2.19.0.tgz#7bd282e3f5842ed295bb748cdd9f1ffa2c824685"
@@ -7224,7 +7116,7 @@ mz@^2.6.0:
object-assign "^4.0.1"
thenify-all "^1.0.0"
-nan@^2.10.0, nan@^2.6.2, nan@^2.9.2:
+nan@^2.10.0, nan@^2.9.2:
version "2.11.1"
resolved "https://registry.yarnpkg.com/nan/-/nan-2.11.1.tgz#90e22bccb8ca57ea4cd37cc83d3819b52eea6766"
@@ -7313,12 +7205,6 @@ no-case@^2.2.0:
dependencies:
lower-case "^1.1.1"
-node-abi@^2.2.0:
- version "2.5.0"
- resolved "https://registry.yarnpkg.com/node-abi/-/node-abi-2.5.0.tgz#942e1a78bce764bc0c1672d5821e492b9d032052"
- dependencies:
- semver "^5.4.1"
-
node-fetch@^1.0.1:
version "1.7.3"
resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-1.7.3.tgz#980f6f72d85211a5347c6b2bc18c5b84c3eb47ef"
@@ -7326,7 +7212,7 @@ node-fetch@^1.0.1:
encoding "^0.1.11"
is-stream "^1.0.1"
-node-gyp@^3.6.2, node-gyp@^3.8.0:
+node-gyp@^3.8.0:
version "3.8.0"
resolved "https://registry.yarnpkg.com/node-gyp/-/node-gyp-3.8.0.tgz#540304261c330e80d0d5edce253a68cb3964218c"
dependencies:
@@ -7410,10 +7296,6 @@ node-sass@^4.9.3:
stdout-stream "^1.4.0"
"true-case-path" "^1.0.2"
-noop-logger@^0.1.1:
- version "0.1.1"
- resolved "https://registry.yarnpkg.com/noop-logger/-/noop-logger-0.1.1.tgz#94a2b1633c4f1317553007d8966fd0e841b6a4c2"
-
nopt@1.0.10:
version "1.0.10"
resolved "https://registry.yarnpkg.com/nopt/-/nopt-1.0.10.tgz#6ddd21bd2a31417b92727dd585f8a6f37608ebee"
@@ -7478,7 +7360,7 @@ npm-run-path@^2.0.0:
dependencies:
path-key "^2.0.0"
-"npmlog@0 || 1 || 2 || 3 || 4", npmlog@^4.0.0, npmlog@^4.0.1, npmlog@^4.0.2, npmlog@^4.1.2:
+"npmlog@0 || 1 || 2 || 3 || 4", npmlog@^4.0.0, npmlog@^4.0.2, npmlog@^4.1.2:
version "4.1.2"
resolved "https://registry.yarnpkg.com/npmlog/-/npmlog-4.1.2.tgz#08a7f2a8bf734604779a9efa4ad5cc717abb954b"
dependencies:
@@ -8345,26 +8227,6 @@ postcss@^6.0.0, postcss@^6.0.1, postcss@^6.0.20, postcss@^6.0.23:
source-map "^0.6.1"
supports-color "^5.4.0"
-prebuild-install@^2.3.0:
- version "2.5.3"
- resolved "https://registry.yarnpkg.com/prebuild-install/-/prebuild-install-2.5.3.tgz#9f65f242782d370296353710e9bc843490c19f69"
- dependencies:
- detect-libc "^1.0.3"
- expand-template "^1.0.2"
- github-from-package "0.0.0"
- minimist "^1.2.0"
- mkdirp "^0.5.1"
- node-abi "^2.2.0"
- noop-logger "^0.1.1"
- npmlog "^4.0.1"
- os-homedir "^1.0.1"
- pump "^2.0.1"
- rc "^1.1.6"
- simple-get "^2.7.0"
- tar-fs "^1.13.0"
- tunnel-agent "^0.6.0"
- which-pm-runs "^1.0.0"
-
prelude-ls@~1.1.2:
version "1.1.2"
resolved "https://registry.yarnpkg.com/prelude-ls/-/prelude-ls-1.1.2.tgz#21932a549f5e52ffd9a827f570e04be62a97da54"
@@ -8396,12 +8258,6 @@ pretty-time@^1.1.0:
version "1.1.0"
resolved "https://registry.yarnpkg.com/pretty-time/-/pretty-time-1.1.0.tgz#ffb7429afabb8535c346a34e41873adf3d74dd0e"
-prettycli@^1.4.3:
- version "1.4.3"
- resolved "https://registry.yarnpkg.com/prettycli/-/prettycli-1.4.3.tgz#b28ec2aad9de07ae1fd75ef294fb54cbdee07ed5"
- dependencies:
- chalk "2.1.0"
-
print-message@^2.1.0:
version "2.1.0"
resolved "https://registry.yarnpkg.com/print-message/-/print-message-2.1.0.tgz#b5588ed08b0e1bf77ac7bcb5cb78004afaf9a891"
@@ -8478,13 +8334,6 @@ public-encrypt@^4.0.0:
randombytes "^2.0.1"
safe-buffer "^5.1.2"
-pump@^1.0.0:
- version "1.0.3"
- resolved "https://registry.yarnpkg.com/pump/-/pump-1.0.3.tgz#5dfe8311c33bbf6fc18261f9f34702c47c08a954"
- dependencies:
- end-of-stream "^1.1.0"
- once "^1.3.1"
-
pump@^2.0.0, pump@^2.0.1:
version "2.0.1"
resolved "https://registry.yarnpkg.com/pump/-/pump-2.0.1.tgz#12399add6e4cf7526d973cbc8b5ce2e2908b3909"
@@ -8658,7 +8507,7 @@ read@^1.0.4:
dependencies:
mute-stream "~0.0.4"
-"readable-stream@1 || 2", readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.4, readable-stream@^2.0.6, readable-stream@^2.1.5, readable-stream@^2.2.2, readable-stream@^2.3.0, readable-stream@^2.3.3, readable-stream@^2.3.5, readable-stream@^2.3.6, readable-stream@~2.3.6:
+"readable-stream@1 || 2", readable-stream@^2.0.0, readable-stream@^2.0.1, readable-stream@^2.0.2, readable-stream@^2.0.4, readable-stream@^2.0.6, readable-stream@^2.1.5, readable-stream@^2.2.2, readable-stream@^2.3.0, readable-stream@^2.3.3, readable-stream@^2.3.6, readable-stream@~2.3.6:
version "2.3.6"
resolved "http://registry.npmjs.org/readable-stream/-/readable-stream-2.3.6.tgz#b11c27d88b8ff1fbe070643cf94b0c79ae1b0aaf"
dependencies:
@@ -9297,18 +9146,6 @@ signal-exit@^3.0.0, signal-exit@^3.0.2:
version "3.0.2"
resolved "https://registry.yarnpkg.com/signal-exit/-/signal-exit-3.0.2.tgz#b5fdc08f1287ea1178628e415e25132b73646c6d"
-simple-concat@^1.0.0:
- version "1.0.0"
- resolved "https://registry.yarnpkg.com/simple-concat/-/simple-concat-1.0.0.tgz#7344cbb8b6e26fb27d66b2fc86f9f6d5997521c6"
-
-simple-get@^2.7.0:
- version "2.8.1"
- resolved "https://registry.yarnpkg.com/simple-get/-/simple-get-2.8.1.tgz#0e22e91d4575d87620620bc91308d57a77f44b5d"
- dependencies:
- decompress-response "^3.3.0"
- once "^1.3.1"
- simple-concat "^1.0.0"
-
sinon-chai@^3.2.0:
version "3.3.0"
resolved "https://registry.yarnpkg.com/sinon-chai/-/sinon-chai-3.3.0.tgz#8084ff99451064910fbe2c2cb8ab540c00b740ea"
@@ -9784,12 +9621,6 @@ supports-color@^3.2.3:
dependencies:
has-flag "^1.0.0"
-supports-color@^4.0.0:
- version "4.5.0"
- resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-4.5.0.tgz#be7a0de484dec5c5cddf8b3d59125044912f635b"
- dependencies:
- has-flag "^2.0.0"
-
supports-color@^5.3.0, supports-color@^5.4.0, supports-color@^5.5.0:
version "5.5.0"
resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-5.5.0.tgz#e2e69a44ac8772f78a1ec0b35b689df6530efc8f"
@@ -9872,27 +9703,6 @@ tapable@^1.0.0, tapable@^1.1.0:
version "1.1.1"
resolved "https://registry.yarnpkg.com/tapable/-/tapable-1.1.1.tgz#4d297923c5a72a42360de2ab52dadfaaec00018e"
-tar-fs@^1.13.0:
- version "1.16.3"
- resolved "https://registry.yarnpkg.com/tar-fs/-/tar-fs-1.16.3.tgz#966a628841da2c4010406a82167cbd5e0c72d509"
- dependencies:
- chownr "^1.0.1"
- mkdirp "^0.5.1"
- pump "^1.0.0"
- tar-stream "^1.1.2"
-
-tar-stream@^1.1.2:
- version "1.6.2"
- resolved "https://registry.yarnpkg.com/tar-stream/-/tar-stream-1.6.2.tgz#8ea55dab37972253d9a9af90fdcd559ae435c555"
- dependencies:
- bl "^1.0.0"
- buffer-alloc "^1.2.0"
- end-of-stream "^1.0.0"
- fs-constants "^1.0.0"
- readable-stream "^2.3.0"
- to-buffer "^1.1.1"
- xtend "^4.0.0"
-
tar@^2.0.0:
version "2.2.1"
resolved "http://registry.npmjs.org/tar/-/tar-2.2.1.tgz#8e4d2a256c0e2185c6b18ad694aec968b83cb1d1"
@@ -10047,10 +9857,6 @@ to-arraybuffer@^1.0.0:
version "1.0.1"
resolved "https://registry.yarnpkg.com/to-arraybuffer/-/to-arraybuffer-1.0.1.tgz#7d229b1fcc637e466ca081180836a7aabff83f43"
-to-buffer@^1.1.1:
- version "1.1.1"
- resolved "https://registry.yarnpkg.com/to-buffer/-/to-buffer-1.1.1.tgz#493bd48f62d7c43fcded313a03dcadb2e1213a80"
-
to-factory@^1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/to-factory/-/to-factory-1.0.0.tgz#8738af8bd97120ad1d4047972ada5563bf9479b1"
@@ -10899,10 +10705,6 @@ which-module@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/which-module/-/which-module-2.0.0.tgz#d9ef07dce77b9902b8a3a8fa4b31c3e3f7e6e87a"
-which-pm-runs@^1.0.0:
- version "1.0.0"
- resolved "https://registry.yarnpkg.com/which-pm-runs/-/which-pm-runs-1.0.0.tgz#670b3afbc552e0b55df6b7780ca74615f23ad1cb"
-
which@1, which@^1.2.1, which@^1.2.10, which@^1.2.14, which@^1.2.9:
version "1.3.1"
resolved "https://registry.yarnpkg.com/which/-/which-1.3.1.tgz#a45043d54f5805316da8d62f9f50918d3da70b0a"
From 8d68bf438fdf522684f1ec4dcf71c891224f93bd Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 13:40:02 +0100
Subject: [PATCH 16/42] updated docs config
---
docs/.vuepress/config.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/.vuepress/config.js b/docs/.vuepress/config.js
index a93c0b326c..0b0bbdfb84 100644
--- a/docs/.vuepress/config.js
+++ b/docs/.vuepress/config.js
@@ -1,5 +1,5 @@
module.exports = {
- base: '/vue-storefront/',
+ base: '/',
head: [['link', { rel: 'icon', href: '/favicon.png' }]],
themeConfig: {
repo: 'DivanteLtd/vue-storefront',
From 08c5aa1cfb2dd8f212240c490a5ce9de4608ff79 Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 13:43:03 +0100
Subject: [PATCH 17/42] Update config.js
---
docs/.vuepress/config.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/.vuepress/config.js b/docs/.vuepress/config.js
index a93c0b326c..0b0bbdfb84 100644
--- a/docs/.vuepress/config.js
+++ b/docs/.vuepress/config.js
@@ -1,5 +1,5 @@
module.exports = {
- base: '/vue-storefront/',
+ base: '/',
head: [['link', { rel: 'icon', href: '/favicon.png' }]],
themeConfig: {
repo: 'DivanteLtd/vue-storefront',
From 9eef20916269aeabc708b41941a5b6b0f109ffdd Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 13:43:41 +0100
Subject: [PATCH 18/42] Create CNAME
---
docs/CNAME | 1 +
1 file changed, 1 insertion(+)
create mode 100644 docs/CNAME
diff --git a/docs/CNAME b/docs/CNAME
new file mode 100644
index 0000000000..51fee44682
--- /dev/null
+++ b/docs/CNAME
@@ -0,0 +1 @@
+docs.vuestorefront.io
\ No newline at end of file
From b650c3c977be6974faf7aa23bdbeb09351caf716 Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 13:47:03 +0100
Subject: [PATCH 19/42] Update config.js
---
docs/.vuepress/config.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/.vuepress/config.js b/docs/.vuepress/config.js
index 0b0bbdfb84..a93c0b326c 100644
--- a/docs/.vuepress/config.js
+++ b/docs/.vuepress/config.js
@@ -1,5 +1,5 @@
module.exports = {
- base: '/',
+ base: '/vue-storefront/',
head: [['link', { rel: 'icon', href: '/favicon.png' }]],
themeConfig: {
repo: 'DivanteLtd/vue-storefront',
From 32d980be0bb0c60d0694516309fcea54d88fa54c Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 13:59:10 +0100
Subject: [PATCH 20/42] corrected master docs
---
docs/.vuepress/config.js | 2 +-
docs/deploy.sh | 1 +
2 files changed, 2 insertions(+), 1 deletion(-)
diff --git a/docs/.vuepress/config.js b/docs/.vuepress/config.js
index 0b0bbdfb84..a93c0b326c 100644
--- a/docs/.vuepress/config.js
+++ b/docs/.vuepress/config.js
@@ -1,5 +1,5 @@
module.exports = {
- base: '/',
+ base: '/vue-storefront/',
head: [['link', { rel: 'icon', href: '/favicon.png' }]],
themeConfig: {
repo: 'DivanteLtd/vue-storefront',
diff --git a/docs/deploy.sh b/docs/deploy.sh
index ab56466785..0874d8f231 100755
--- a/docs/deploy.sh
+++ b/docs/deploy.sh
@@ -4,6 +4,7 @@
set -e
# build
+npm i
npm run docs:build
# navigate into the build output directory
From 69308318d08781d2553444c18ffee8edda3ead06 Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 14:12:14 +0100
Subject: [PATCH 21/42] Update config.js
---
docs/.vuepress/config.js | 1 -
1 file changed, 1 deletion(-)
diff --git a/docs/.vuepress/config.js b/docs/.vuepress/config.js
index a93c0b326c..c950e4a810 100644
--- a/docs/.vuepress/config.js
+++ b/docs/.vuepress/config.js
@@ -1,5 +1,4 @@
module.exports = {
- base: '/vue-storefront/',
head: [['link', { rel: 'icon', href: '/favicon.png' }]],
themeConfig: {
repo: 'DivanteLtd/vue-storefront',
From e4828930cde83e30e8dc5941f1ccbd7b2d85ec0d Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 14:16:49 +0100
Subject: [PATCH 22/42] Update config.js
---
docs/.vuepress/config.js | 1 +
1 file changed, 1 insertion(+)
diff --git a/docs/.vuepress/config.js b/docs/.vuepress/config.js
index c950e4a810..0b0bbdfb84 100644
--- a/docs/.vuepress/config.js
+++ b/docs/.vuepress/config.js
@@ -1,4 +1,5 @@
module.exports = {
+ base: '/',
head: [['link', { rel: 'icon', href: '/favicon.png' }]],
themeConfig: {
repo: 'DivanteLtd/vue-storefront',
From f46ab60b99785ef10fe356af139ffd34a507fc52 Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 15:20:08 +0100
Subject: [PATCH 23/42] Create introduction.md
---
docs/guide/extensions/introduction.md | 14 ++++++++++++++
1 file changed, 14 insertions(+)
create mode 100644 docs/guide/extensions/introduction.md
diff --git a/docs/guide/extensions/introduction.md b/docs/guide/extensions/introduction.md
new file mode 100644
index 0000000000..3fd40cd8a9
--- /dev/null
+++ b/docs/guide/extensions/introduction.md
@@ -0,0 +1,14 @@
+# How Vue Storefront extensions work?
+Depending on needs Vue Storefront extensions can have two parts:
+- **Client-side part** which is just a [Vue Storefront module](https://github.com/DivanteLtd/vue-storefront/blob/master/docs/guide/modules/introduction.md). It covers most of the use cases.
+- **Server-side part** which is a [Vue Storefront API extension](https://github.com/DivanteLtd/vue-storefront/blob/master/docs/guide/extensions/extending-api.md) and should be used if you want to add some endpoints to `vue-storefront-api` or interact directly with server side code.
+
+# Where extensions are located
+- On the client side extension modules should be placed in `src/modules` folder of `vue-storefront` and registered in `src/modules/index.ts`
+- On the server side extensions should be placed in `src/api/extensions` folder of `vue-storefront-api` and registered in config file
+
+# Writing extensions
+[section under construction]
+Here you can find two articles explaining how to create custom Vue Storefront extensions:
+- [How to create an Instagram Feed module for Vue Storefront](https://itnext.io/how-to-create-an-instagram-feed-module-for-vue-storefront-eaa03019b288)
+- [Developing a Vue Storefront payment module](https://www.develodesign.co.uk/news/development-of-the-paypal-module-for-vue-storefront/#.XCoa2h2Mmmo.twitter)
From b8cb929e5e3f9ab58a2cafb1bec12acc1935c333 Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 15:20:35 +0100
Subject: [PATCH 24/42] Update introduction.md
---
docs/guide/extensions/introduction.md | 1 -
1 file changed, 1 deletion(-)
diff --git a/docs/guide/extensions/introduction.md b/docs/guide/extensions/introduction.md
index 3fd40cd8a9..e9aac1da8d 100644
--- a/docs/guide/extensions/introduction.md
+++ b/docs/guide/extensions/introduction.md
@@ -8,7 +8,6 @@ Depending on needs Vue Storefront extensions can have two parts:
- On the server side extensions should be placed in `src/api/extensions` folder of `vue-storefront-api` and registered in config file
# Writing extensions
-[section under construction]
Here you can find two articles explaining how to create custom Vue Storefront extensions:
- [How to create an Instagram Feed module for Vue Storefront](https://itnext.io/how-to-create-an-instagram-feed-module-for-vue-storefront-eaa03019b288)
- [Developing a Vue Storefront payment module](https://www.develodesign.co.uk/news/development-of-the-paypal-module-for-vue-storefront/#.XCoa2h2Mmmo.twitter)
From 1943affba0518b1b8cd3fb176286191aa2d0a466 Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 15:23:03 +0100
Subject: [PATCH 25/42] Update config.js
---
docs/.vuepress/config.js | 1 +
1 file changed, 1 insertion(+)
diff --git a/docs/.vuepress/config.js b/docs/.vuepress/config.js
index 0b0bbdfb84..20ea07b19d 100644
--- a/docs/.vuepress/config.js
+++ b/docs/.vuepress/config.js
@@ -86,6 +86,7 @@ module.exports = {
title: 'Extensions',
collapsable: false,
children: [
+ 'extensions/introduction',
'extensions/extending-api',
'extensions/extending-server-side-routes',
],
From 4accc160a414f191873fedf9f4ff015371456ff0 Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 15:25:51 +0100
Subject: [PATCH 26/42] Update introduction.md
---
docs/guide/extensions/introduction.md | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/docs/guide/extensions/introduction.md b/docs/guide/extensions/introduction.md
index e9aac1da8d..aea8bcf47f 100644
--- a/docs/guide/extensions/introduction.md
+++ b/docs/guide/extensions/introduction.md
@@ -9,5 +9,8 @@ Depending on needs Vue Storefront extensions can have two parts:
# Writing extensions
Here you can find two articles explaining how to create custom Vue Storefront extensions:
-- [How to create an Instagram Feed module for Vue Storefront](https://itnext.io/how-to-create-an-instagram-feed-module-for-vue-storefront-eaa03019b288)
-- [Developing a Vue Storefront payment module](https://www.develodesign.co.uk/news/development-of-the-paypal-module-for-vue-storefront/#.XCoa2h2Mmmo.twitter)
+- [How to create an Instagram Feed module for Vue Storefront](https://itnext.io/how-to-create-an-instagram-feed-module-for-vue-storefront-eaa03019b288) by Javier Villanueva
+- [Developing a Vue Storefront payment module](https://www.develodesign.co.uk/news/development-of-the-paypal-module-for-vue-storefront/#.XCoa2h2Mmmo.twitter) by Dmitry Schegolikhin from [Develo Design](https://www.develodesign.co.uk/)
+
+# Extensions list
+You can find a curated list of VS extensions in [Awesome Vue Storefront](https://github.com/frqnck/awesome-vue-storefront) list.
From 027ed90c0befd8e514b7b89beca132cbb19ac968 Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 15:26:37 +0100
Subject: [PATCH 27/42] Update introduction.md
---
docs/guide/extensions/introduction.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/guide/extensions/introduction.md b/docs/guide/extensions/introduction.md
index aea8bcf47f..c19ba648f4 100644
--- a/docs/guide/extensions/introduction.md
+++ b/docs/guide/extensions/introduction.md
@@ -1,4 +1,4 @@
-# How Vue Storefront extensions work?
+# How Vue Storefront extensions look like?
Depending on needs Vue Storefront extensions can have two parts:
- **Client-side part** which is just a [Vue Storefront module](https://github.com/DivanteLtd/vue-storefront/blob/master/docs/guide/modules/introduction.md). It covers most of the use cases.
- **Server-side part** which is a [Vue Storefront API extension](https://github.com/DivanteLtd/vue-storefront/blob/master/docs/guide/extensions/extending-api.md) and should be used if you want to add some endpoints to `vue-storefront-api` or interact directly with server side code.
From 4bb1ca09738c682b94108bda7f4dcad628b0c04e Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 15:28:33 +0100
Subject: [PATCH 28/42] Update introduction.md
---
docs/guide/extensions/introduction.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/guide/extensions/introduction.md b/docs/guide/extensions/introduction.md
index c19ba648f4..bd19488427 100644
--- a/docs/guide/extensions/introduction.md
+++ b/docs/guide/extensions/introduction.md
@@ -1,7 +1,7 @@
# How Vue Storefront extensions look like?
Depending on needs Vue Storefront extensions can have two parts:
- **Client-side part** which is just a [Vue Storefront module](https://github.com/DivanteLtd/vue-storefront/blob/master/docs/guide/modules/introduction.md). It covers most of the use cases.
-- **Server-side part** which is a [Vue Storefront API extension](https://github.com/DivanteLtd/vue-storefront/blob/master/docs/guide/extensions/extending-api.md) and should be used if you want to add some endpoints to `vue-storefront-api` or interact directly with server side code.
+- **Server-side part** which is a [Vue Storefront API extension](https://github.com/DivanteLtd/vue-storefront/blob/master/docs/guide/extensions/extending-api.md) and should be used if you want to add some endpoints to `vue-storefront-api` or interact with Elastic Search.
# Where extensions are located
- On the client side extension modules should be placed in `src/modules` folder of `vue-storefront` and registered in `src/modules/index.ts`
From 07ddff742641028c40dffff92ef559373188133a Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 15:31:58 +0100
Subject: [PATCH 29/42] Update introduction.md
---
docs/guide/extensions/introduction.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/guide/extensions/introduction.md b/docs/guide/extensions/introduction.md
index bd19488427..868492ad04 100644
--- a/docs/guide/extensions/introduction.md
+++ b/docs/guide/extensions/introduction.md
@@ -8,7 +8,7 @@ Depending on needs Vue Storefront extensions can have two parts:
- On the server side extensions should be placed in `src/api/extensions` folder of `vue-storefront-api` and registered in config file
# Writing extensions
-Here you can find two articles explaining how to create custom Vue Storefront extensions:
+If you are writing VS extension as an NPM modul start package name with `vsf-` prefix so it can be transpiled with other VS code and ship it as a raw es6/typescript module (we are currently building extension boilerplate to make it easier to develop one). Here you can find two articles explaining how to create custom Vue Storefront extensions:
- [How to create an Instagram Feed module for Vue Storefront](https://itnext.io/how-to-create-an-instagram-feed-module-for-vue-storefront-eaa03019b288) by Javier Villanueva
- [Developing a Vue Storefront payment module](https://www.develodesign.co.uk/news/development-of-the-paypal-module-for-vue-storefront/#.XCoa2h2Mmmo.twitter) by Dmitry Schegolikhin from [Develo Design](https://www.develodesign.co.uk/)
From 2c3ce4d936890e66072a5ea517a04937ef3cab8c Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 15:32:41 +0100
Subject: [PATCH 30/42] Update introduction.md
---
docs/guide/extensions/introduction.md | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/docs/guide/extensions/introduction.md b/docs/guide/extensions/introduction.md
index 868492ad04..28b5377efd 100644
--- a/docs/guide/extensions/introduction.md
+++ b/docs/guide/extensions/introduction.md
@@ -8,7 +8,9 @@ Depending on needs Vue Storefront extensions can have two parts:
- On the server side extensions should be placed in `src/api/extensions` folder of `vue-storefront-api` and registered in config file
# Writing extensions
-If you are writing VS extension as an NPM modul start package name with `vsf-` prefix so it can be transpiled with other VS code and ship it as a raw es6/typescript module (we are currently building extension boilerplate to make it easier to develop one). Here you can find two articles explaining how to create custom Vue Storefront extensions:
+If you are writing VS extension as an NPM module start package name with `vsf-` prefix so it can be transpiled with other VS code and ship it as a raw es6/typescript module (we are currently building extension boilerplate to make it easier to develop one).
+
+Here you can find two articles explaining how to create custom Vue Storefront extensions:
- [How to create an Instagram Feed module for Vue Storefront](https://itnext.io/how-to-create-an-instagram-feed-module-for-vue-storefront-eaa03019b288) by Javier Villanueva
- [Developing a Vue Storefront payment module](https://www.develodesign.co.uk/news/development-of-the-paypal-module-for-vue-storefront/#.XCoa2h2Mmmo.twitter) by Dmitry Schegolikhin from [Develo Design](https://www.develodesign.co.uk/)
From 2b2f389ff34ea84e243486e3abfb3b37c2ff4115 Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 15:33:35 +0100
Subject: [PATCH 31/42] Update introduction.md
---
docs/guide/extensions/introduction.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/guide/extensions/introduction.md b/docs/guide/extensions/introduction.md
index 28b5377efd..8d2fe30518 100644
--- a/docs/guide/extensions/introduction.md
+++ b/docs/guide/extensions/introduction.md
@@ -8,7 +8,7 @@ Depending on needs Vue Storefront extensions can have two parts:
- On the server side extensions should be placed in `src/api/extensions` folder of `vue-storefront-api` and registered in config file
# Writing extensions
-If you are writing VS extension as an NPM module start package name with `vsf-` prefix so it can be transpiled with other VS code and ship it as a raw es6/typescript module (we are currently building extension boilerplate to make it easier to develop one).
+If you are writing VS extension as an NPM module start package name with `vsf-` prefix so it can be transpiled with other VS code and ship it as a raw es6/typescript module. If you don't use the prefix you need to handle transpilation by yourself. We are currently building extension boilerplate to make it easier to develop one.
Here you can find two articles explaining how to create custom Vue Storefront extensions:
- [How to create an Instagram Feed module for Vue Storefront](https://itnext.io/how-to-create-an-instagram-feed-module-for-vue-storefront-eaa03019b288) by Javier Villanueva
From 2c1c472048e37dcb1a0d177ca050197d01fad241 Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 15:34:36 +0100
Subject: [PATCH 32/42] Update introduction.md
---
docs/guide/extensions/introduction.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/guide/extensions/introduction.md b/docs/guide/extensions/introduction.md
index 8d2fe30518..e61fa30ee6 100644
--- a/docs/guide/extensions/introduction.md
+++ b/docs/guide/extensions/introduction.md
@@ -4,7 +4,7 @@ Depending on needs Vue Storefront extensions can have two parts:
- **Server-side part** which is a [Vue Storefront API extension](https://github.com/DivanteLtd/vue-storefront/blob/master/docs/guide/extensions/extending-api.md) and should be used if you want to add some endpoints to `vue-storefront-api` or interact with Elastic Search.
# Where extensions are located
-- On the client side extension modules should be placed in `src/modules` folder of `vue-storefront` and registered in `src/modules/index.ts`
+- On the client side extension modules should be placed in `src/modules` folder of `vue-storefront` or installed via NPM cli and registered in `src/modules/index.ts`
- On the server side extensions should be placed in `src/api/extensions` folder of `vue-storefront-api` and registered in config file
# Writing extensions
From c7f45d261163aa364ac7aa7c14d8daa58817741a Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 15:35:39 +0100
Subject: [PATCH 33/42] Update introduction.md
---
docs/guide/extensions/introduction.md | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/docs/guide/extensions/introduction.md b/docs/guide/extensions/introduction.md
index e61fa30ee6..18581145b5 100644
--- a/docs/guide/extensions/introduction.md
+++ b/docs/guide/extensions/introduction.md
@@ -1,18 +1,20 @@
-# How Vue Storefront extensions look like?
+# Introduction
+
+## How Vue Storefront extensions look like?
Depending on needs Vue Storefront extensions can have two parts:
- **Client-side part** which is just a [Vue Storefront module](https://github.com/DivanteLtd/vue-storefront/blob/master/docs/guide/modules/introduction.md). It covers most of the use cases.
- **Server-side part** which is a [Vue Storefront API extension](https://github.com/DivanteLtd/vue-storefront/blob/master/docs/guide/extensions/extending-api.md) and should be used if you want to add some endpoints to `vue-storefront-api` or interact with Elastic Search.
-# Where extensions are located
+## Where extensions are located
- On the client side extension modules should be placed in `src/modules` folder of `vue-storefront` or installed via NPM cli and registered in `src/modules/index.ts`
- On the server side extensions should be placed in `src/api/extensions` folder of `vue-storefront-api` and registered in config file
-# Writing extensions
+## Writing extensions
If you are writing VS extension as an NPM module start package name with `vsf-` prefix so it can be transpiled with other VS code and ship it as a raw es6/typescript module. If you don't use the prefix you need to handle transpilation by yourself. We are currently building extension boilerplate to make it easier to develop one.
Here you can find two articles explaining how to create custom Vue Storefront extensions:
- [How to create an Instagram Feed module for Vue Storefront](https://itnext.io/how-to-create-an-instagram-feed-module-for-vue-storefront-eaa03019b288) by Javier Villanueva
- [Developing a Vue Storefront payment module](https://www.develodesign.co.uk/news/development-of-the-paypal-module-for-vue-storefront/#.XCoa2h2Mmmo.twitter) by Dmitry Schegolikhin from [Develo Design](https://www.develodesign.co.uk/)
-# Extensions list
+## Extensions list
You can find a curated list of VS extensions in [Awesome Vue Storefront](https://github.com/frqnck/awesome-vue-storefront) list.
From 7aa96c93f19c57891b2d39430f05bac194d6eaf0 Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Mon, 7 Jan 2019 15:36:07 +0100
Subject: [PATCH 34/42] Update introduction.md
---
docs/guide/modules/introduction.md | 1 +
1 file changed, 1 insertion(+)
diff --git a/docs/guide/modules/introduction.md b/docs/guide/modules/introduction.md
index d42098a3e9..01aceba8d2 100644
--- a/docs/guide/modules/introduction.md
+++ b/docs/guide/modules/introduction.md
@@ -1,3 +1,4 @@
+# Introduction
# Table of contents
**Introduction and motivation**
From d7cfb3f4f24c984c8b21fc69337da7e65a19e7f6 Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Tue, 8 Jan 2019 12:46:08 +0100
Subject: [PATCH 35/42] Update amp.md
---
docs/guide/basics/amp.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/docs/guide/basics/amp.md b/docs/guide/basics/amp.md
index c71e85382b..1cbfcd4a4d 100644
--- a/docs/guide/basics/amp.md
+++ b/docs/guide/basics/amp.md
@@ -1,4 +1,4 @@
-# Google Advanced Mobile Pages
+# Google Accelerated Mobile Pages
Google Advanced Mobile pages are available with Vue Storefront 1.6. By default, the Product and Category pages do support AMP. To get the AMP page You should use the following URL:
`http://localhost:3000/c/hoodies-and-sweatshirts-24` -> `http://localhost:3000/amp/c/hoodies-and-sweatshirts-24`.
From 3f1775de62a46f9d0d3a322aac226ce9a065b0f4 Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Wed, 9 Jan 2019 10:45:36 +0100
Subject: [PATCH 36/42] Update introduction.md
---
docs/guide/modules/introduction.md | 18 +++++++++---------
1 file changed, 9 insertions(+), 9 deletions(-)
diff --git a/docs/guide/modules/introduction.md b/docs/guide/modules/introduction.md
index 01aceba8d2..6105ca88c7 100644
--- a/docs/guide/modules/introduction.md
+++ b/docs/guide/modules/introduction.md
@@ -2,19 +2,19 @@
# Table of contents
**Introduction and motivation**
-- [What are VS Modules](https://github.com/DivanteLtd/vue-storefront/blob/master/doc/api-modules/about-modules.md#what-are-vs-modules)
-- [Motivation](https://github.com/DivanteLtd/vue-storefront/blob/master/doc/api-modules/about-modules.md#motivation)
-- [What is the purpose of VS modules?](https://github.com/DivanteLtd/vue-storefront/blob/master/doc/api-modules/about-modules.md#what-is-the-purpose-of-vs-modules)
+- [What are VS Modules](#what-are-vs-modules)
+- [Motivation](#motivation)
+- [What is the purpose of VS modules?](#what-is-the-purpose-of-vs-modules)
**Technical part**
-- [Module config and it's capabilities](https://github.com/DivanteLtd/vue-storefront/blob/master/doc/api-modules/about-modules.md#module-config-and-capabilities)
-- [Module file structure](https://github.com/DivanteLtd/vue-storefront/blob/master/doc/api-modules/about-modules.md#module-file-structure)
-- [Module registration](https://github.com/DivanteLtd/vue-storefront/blob/master/doc/api-modules/about-modules.md#module-registration)
+- [Module config and it's capabilities](#module-config-and-capabilities)
+- [Module file structure](#module-file-structure)
+- [Module registration](#module-registration)
**Patterns and good practices for common use cases**
-- [General rules and good practices](https://github.com/DivanteLtd/vue-storefront/blob/master/doc/api-modules/about-modules.md#general-rules-and-good-practices)
-- [Adding new features as VS modules](https://github.com/DivanteLtd/vue-storefront/blob/master/doc/api-modules/about-modules.md#adding-new-features-as-vs-modules)
-- [Extending and overriding Vue Storefront modules](https://github.com/DivanteLtd/vue-storefront/blob/master/doc/api-modules/about-modules.md#extending-and-overriding-vue-storefront-modules)
+- [General rules and good practices](#general-rules-and-good-practices)
+- [Adding new features as VS modules](#adding-new-features-as-vs-modules)
+- [Extending and overriding Vue Storefront modules](#extending-and-overriding-vue-storefront-modules)
# What are VS modules?
From 1047a8a570ca38b0d8b0a1a9f0b94cbe48af284c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Tomasz=20Anio=C5=82?=
<33483514+tom-aniol@users.noreply.github.com>
Date: Wed, 9 Jan 2019 14:27:46 +0100
Subject: [PATCH 37/42] Update Readme
---
README.md | 42 +++++-------------------------------------
1 file changed, 5 insertions(+), 37 deletions(-)
diff --git a/README.md b/README.md
index 32ec9a7dd4..19432cf6d2 100644
--- a/README.md
+++ b/README.md
@@ -274,7 +274,7 @@ Vue Storefront is a Community effort brought to You by our great Core Team and s
@@ -535,42 +535,10 @@ Vue Storefront is a Community effort brought to You by our great Core Team and s
>
|
-
-
-
-
- |
-
-
-
-
- |
-
-
-
-
- |
-
-
-
-
- |
+ |
+ |
+ |
+ |
From 97ad959836105d0e465e533c59a720162b90facd Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Tue, 15 Jan 2019 09:27:09 +0100
Subject: [PATCH 38/42] Module extending made easier / bug corrected
---
core/lib/module.ts | 7 ++++-
src/modules/index.ts | 28 +++++++++++++------
src/modules/module-template/index.ts | 2 +-
.../module-template/store/mailchimp/index.ts | 22 ---------------
4 files changed, 26 insertions(+), 33 deletions(-)
delete mode 100644 src/modules/module-template/store/mailchimp/index.ts
diff --git a/core/lib/module.ts b/core/lib/module.ts
index 25666a11d4..f1a0a3dbfd 100644
--- a/core/lib/module.ts
+++ b/core/lib/module.ts
@@ -32,6 +32,10 @@ export class VueStorefrontModule {
return this._c
}
+ public set config (config) {
+ this._c = config
+ }
+
private static _registeredModules: VueStorefrontModuleConfig[] = []
private static _doesStoreAlreadyExists (key: string) : boolean {
@@ -60,8 +64,9 @@ export class VueStorefrontModule {
private _extend (extendedConfig: VueStorefrontModule) {
const key = this._c.key
- this._c = merge(this._c, extendedConfig.config)
+ this._c = merge(this._c, extendedConfig)
Logger.info('Module "' + key + '" has been succesfully extended.', 'module')()
+ debugger;
}
public register (): VueStorefrontModuleConfig | void {
diff --git a/src/modules/index.ts b/src/modules/index.ts
index 7e5d3fbef3..f13b191a84 100644
--- a/src/modules/index.ts
+++ b/src/modules/index.ts
@@ -1,4 +1,4 @@
-// import { extendModule } from '@vue-storefront/core/lib/module'
+import { extendModule } from '@vue-storefront/core/lib/module'
import { VueStorefrontModule } from '@vue-storefront/core/lib/module'
import { Catalog } from "@vue-storefront/core/modules/catalog"
import { Cart } from '@vue-storefront/core/modules/cart'
@@ -21,20 +21,30 @@ import { PaymentCashOnDelivery } from './payment-cash-on-delivery';
import { RawOutputExample } from './raw-output-example'
import { Magento2CMS } from './magento-2-cms'
-// Some modules that still needs API refactoring are temporary registered in core
-// This is how you can adjust any module with application-specific behavior
-// const extendedExample = {
-// key: 'example',
-// afterRegistration: function(isServer, config) {
-// console.info('Hello, im extended now!')
+
+// This is how you can extend any of VS modues
+// const extendCartVuex = {
+// actions: {
+// load () {
+// console.info('New load function')
+// }
// }
-// }
+// }
-// extendModule(extendedExample)
+// const cartExtend = {
+// key: 'cart',
+// afterRegistration: function(isServer, config) {
+// console.info('New afterRegistration hook')
+// },
+// store: { modules: [{ key: 'cart', module: extendCartVuex }] },
+// }
+
+// extendModule(cartExtend)
/**
* Some of the modules are registered lazily only when components from module are appearing on current page.
* If you want to use this modules in pages without it's components you need to remember about registering module first
+ * In VS 1.8 this modules will be semlessly lazyLoaded after proper action dispatch
* - Wishlist
*/
export const registerModules: VueStorefrontModule[] = [
diff --git a/src/modules/module-template/index.ts b/src/modules/module-template/index.ts
index 4c78752d01..2c53165f6e 100644
--- a/src/modules/module-template/index.ts
+++ b/src/modules/module-template/index.ts
@@ -17,7 +17,7 @@ export const cacheStorage = initCacheStorage(KEY)
// Put everything that should extend the base app here so it can be later registered as VS module
const moduleConfig: VueStorefrontModuleConfig = {
key: KEY,
- store: { modules: [{ key: KEY, module }, { key: 'mailchimp', module: extendMailchimp }], plugin },
+ store: { modules: [{ key: KEY, module }], plugin },
beforeRegistration,
afterRegistration,
router: { beforeEach, afterEach }
diff --git a/src/modules/module-template/store/mailchimp/index.ts b/src/modules/module-template/store/mailchimp/index.ts
deleted file mode 100644
index 024d9be6c0..0000000000
--- a/src/modules/module-template/store/mailchimp/index.ts
+++ /dev/null
@@ -1,22 +0,0 @@
-// With store.extend property you can extend currently existing VS modules.
-// Vuex Module below will be merged with the one with the same key property.
-// You can add new properties to currently existing stores or override existing ones just by using the same name
-// In this example we will override mailchimp vuex store
-import { Module } from 'vuex'
-
-// you can use mailchimp state instead of any
-export const extendMailchimp: Module = {
- state: {
- addedproperty: 'Hello!'
- },
- actions: {
- unsubscribe () {
- // mailchimp module 'unsubscribe' action will be overwritten by this one
- console.info('Hello from mailchimp module extension! Now this action is broken ;o')
- },
- logHello () {
- // this action will be added to mailchimp vuex module
- console.info('Hello!')
- }
- }
-}
\ No newline at end of file
From bbc668961d993a4a570be631479562f005e68f3f Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Tue, 15 Jan 2019 09:27:32 +0100
Subject: [PATCH 39/42] extendModule commented out
---
src/modules/index.ts | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/modules/index.ts b/src/modules/index.ts
index f13b191a84..7709468d6f 100644
--- a/src/modules/index.ts
+++ b/src/modules/index.ts
@@ -1,4 +1,4 @@
-import { extendModule } from '@vue-storefront/core/lib/module'
+// import { extendModule } from '@vue-storefront/core/lib/module'
import { VueStorefrontModule } from '@vue-storefront/core/lib/module'
import { Catalog } from "@vue-storefront/core/modules/catalog"
import { Cart } from '@vue-storefront/core/modules/cart'
From 655d7317f0fa6bf6d111c7a3a9c04a70d167f771 Mon Sep 17 00:00:00 2001
From: Patryk Tomczyk <13100280+patzick@users.noreply.github.com>
Date: Tue, 15 Jan 2019 11:54:51 +0100
Subject: [PATCH 40/42] add notes of changes in theme
---
docs/guide/upgrade-notes/README.md | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/docs/guide/upgrade-notes/README.md b/docs/guide/upgrade-notes/README.md
index f866de2468..c3115e29bd 100644
--- a/docs/guide/upgrade-notes/README.md
+++ b/docs/guide/upgrade-notes/README.md
@@ -8,6 +8,10 @@ Starting from Vue Storefront 1.7 we've changed the Caching strategy + Offline re
- by default, the ElasticSearch Queries are executed using `GET` method - and therefore are cached by Service Worker (`config.elasticsearch.queryMethod` - set it to POST for the previous behavior and if You're using graphql),
- by default products and queries cache is set in the `LocalStorage` with a quota set to 4MB (`config.server.elasticCacheQuota`). If the storage quota is set, the cache purging is executed each 30s using LRU algorithm. Local Storage is limited to 5MB in most browsers
- we've added `config.server. disableLocalStorageQueriesCache` which is set to `true` by default. When this option is `on` then we're not storing the ElasticSearch results in local cache - this is due to the fact that results are by default cached in Service Worker cache anyway.
+- `module.extend` has been changed to `extendModule`. You can find usage example in `src/modules/index.ts`.
+- [routes](https://github.com/patzick/vue-storefront/commit/a97eb11868de2915e86d57c4279caf944d4de422#diff-a334a7caeb7f61836f8c1178d92de3e0), [layouts](https://github.com/patzick/vue-storefront/commit/a97eb11868de2915e86d57c4279caf944d4de422#diff-48863b9fe31d7713222ec5709ef5a4fa) and component, which are not visible at page rendering are now loaded when they are needed
+- Every store manipulation should be done by dispatching actions. Invoke store dispatch on `category/mergeSearchOptions` when manipulating `store.state.category.current_product_query` somewhere.
+- [here](https://github.com/patzick/vue-storefront/commit/a97eb11868de2915e86d57c4279caf944d4de422) are all changes in default themes
Backward compatibility - to reverse to the 1.0-1.6 behavior please set:
- set `config.server.disableLocalStorageQueriesCache` = `false`,
@@ -144,11 +148,7 @@ Required action: Add moved content and remove core import. In case of additional
- [`ProductBundleOptions.vue`](https://github.com/DivanteLtd/vue-storefront/commit/cc17b5bfa43a9510815aea14dce8bafac382bc7f#diff-7ccee94c636406b1a82feddea3a7f520) - single option moved to separate component `ProductBundleOption.vue`, moved to module.
- [`ThankYouPage.vue`](https://github.com/DivanteLtd/vue-storefront/commit/cc17b5bfa43a9510815aea14dce8bafac382bc7f#diff-84c29c5b22568c31b021dc864221563f) added order id display, order confirmation, pulled notifications from core and added mail confirmation
- [`main.scss`](https://github.com/DivanteLtd/vue-storefront/commit/cc17b5bfa43a9510815aea14dce8bafac382bc7f#diff-c65e47159738f3552a22f16ec5c5974f) removed duplicated flexbox grid
-<<<<<<< HEAD
-- [`index.template.html`](https://github.com/DivanteLtd/vue-storefront/commit/cc17b5bfa43a9510815aea14dce8bafac382bc7f#diff-bf0804a2329350f8e9d9071e40cf1429) (+ all other templates that you may have like minimal, basic etc), added output.appendHead(), renderStyles()
-=======
- [`index.template.html`](https://github.com/DivanteLtd/vue-storefront/commit/cc17b5bfa43a9510815aea14dce8bafac382bc7f#diff-bf0804a2329350f8e9d9071e40cf1429) (+ all other templates that you may have like minimal, basic etc), added ` output.appendHead(), renderStyles()`
->>>>>>> main/develop
- [`Category.vue`](https://github.com/DivanteLtd/vue-storefront/commit/cc17b5bfa43a9510815aea14dce8bafac382bc7f#diff-eb709969add1ca4a266ac072cddde954) notifications moved to theme
- [`Checkout.vue`](https://github.com/DivanteLtd/vue-storefront/commit/cc17b5bfa43a9510815aea14dce8bafac382bc7f#diff-1c6544c28d075f275812201fa42755de) notifications moved to theme
- [`MyAccount.vue`](https://github.com/DivanteLtd/vue-storefront/commit/cc17b5bfa43a9510815aea14dce8bafac382bc7f#diff-bb873f532ed9a2efbb157af79a70e0f7) notifications moved to theme
From 7c4fc9a8c6dc73bacb82ddd46fa944dfd70bfe34 Mon Sep 17 00:00:00 2001
From: Patryk Tomczyk <13100280+patzick@users.noreply.github.com>
Date: Tue, 15 Jan 2019 11:55:09 +0100
Subject: [PATCH 41/42] fix installer imgUrl
---
core/scripts/installer.js | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/core/scripts/installer.js b/core/scripts/installer.js
index 643be77f44..cce6bcd26a 100644
--- a/core/scripts/installer.js
+++ b/core/scripts/installer.js
@@ -264,7 +264,7 @@ class Backend extends Abstract {
config.imageable.whitelist.allowedHosts.push(host)
config.magento2.url = urlParser(this.answers.m2_url).href
- config.magento2.imgUrl = this.answers.m2_url ? urlParser(this.answers.m2_url).href + '/pub/media/catalog/product' : config.magento2.api.imgUrl
+ config.magento2.imgUrl = this.answers.m2_url ? urlParser(this.answers.m2_url).href + '/pub/media/catalog/product' : config.magento2.imgUrl
config.magento2.api.url = urlParser(this.answers.m2_api_url).href || config.magento2.api.url
config.magento2.api.consumerKey = this.answers.m2_api_consumer_key || config.magento2.api.consumerKey
config.magento2.api.consumerSecret = this.answers.m2_api_consumer_secret || config.magento2.api.consumerSecret
From 48e95836562b18e33b71ffd2ee619a2e11247200 Mon Sep 17 00:00:00 2001
From: Filip Rakowski
Date: Tue, 15 Jan 2019 12:50:42 +0100
Subject: [PATCH 42/42] remove debugger statement
---
core/lib/module.ts | 1 -
1 file changed, 1 deletion(-)
diff --git a/core/lib/module.ts b/core/lib/module.ts
index f1a0a3dbfd..f922eaf5e5 100644
--- a/core/lib/module.ts
+++ b/core/lib/module.ts
@@ -66,7 +66,6 @@ export class VueStorefrontModule {
const key = this._c.key
this._c = merge(this._c, extendedConfig)
Logger.info('Module "' + key + '" has been succesfully extended.', 'module')()
- debugger;
}
public register (): VueStorefrontModuleConfig | void {