@vue-storefront/nuxt 3.0.1 → 3.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,9 +1,17 @@
1
1
  # Change log
2
2
 
3
+ ## 3.0.3
4
+
5
+ - **[CHANGED]** `@nuxt/kit` locked `3.7.4` version to `@nuxt/kit@^3.7.4`
6
+
7
+ ## 3.0.2
8
+
9
+ - **[FIXED]** Multi-store URL calculation, now working correctly in the browser.
10
+
3
11
  ## 3.0.1
4
12
 
5
13
  - **[CHANGED]** Set `@vue-storefront/sdk` as a dependency instead of a peer dependency
6
14
 
7
15
  ## 3.0.0
8
16
 
9
- - **[BREAKING]** Rewritten from scratch. Now the package exports a Nuxt module which allows to initialize the Vue Storefront SDK.
17
+ - **[BREAKING]** Rewritten from scratch. Now the package exports a Nuxt module which allows to initialize the Vue Storefront SDK.
package/dist/module.json CHANGED
@@ -4,5 +4,5 @@
4
4
  "compatibility": {
5
5
  "nuxt": "^3.0.0"
6
6
  },
7
- "version": "3.0.1"
7
+ "version": "3.0.3"
8
8
  }
@@ -4,6 +4,11 @@ function calculateMiddlewareUrl({
4
4
  }) {
5
5
  const { apiUrl, ssrApiUrl } = options.middleware;
6
6
  if (typeof window !== "undefined") {
7
+ if (options.multistore?.enabled) {
8
+ const url2 = new URL(apiUrl);
9
+ url2.host = window.location.host;
10
+ return url2.href;
11
+ }
7
12
  return apiUrl;
8
13
  }
9
14
  if (ssrApiUrl) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vue-storefront/nuxt",
3
- "version": "3.0.1",
3
+ "version": "3.0.3",
4
4
  "description": "Vue Storefront dedicated features for Nuxt",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -28,7 +28,8 @@
28
28
  "prepare": "nuxi prepare"
29
29
  },
30
30
  "dependencies": {
31
- "@nuxt/kit": "3.7.4",
31
+ "@nuxt/kit": "^3.7.4",
32
+ "@nuxt/schema": "^3.7.4",
32
33
  "@vue-storefront/sdk": "^1.0.0",
33
34
  "knitwork": "^1.0.0"
34
35
  },