Vue Storefront Versions Save

Alokai is a Frontend as a Service solution that simplifies composable commerce. It connects all the technologies needed to build and deploy fast & scalable ecommerce frontends. It guides merchants to deliver exceptional customer experiences quickly and easily.

@vue-storefront/[email protected]

2 months ago

Releases

@vue-storefront/[email protected]

Patch Changes

  • [FIXED] error handling for default HTTP client. Default HTTP Client was not throwing an error on each failed request, now it does.

@vue-storefront/[email protected]

2 months ago

Releases

@vue-storefront/[email protected]

Minor changes

  • [ADDED] middlewareModule to createSdk params.
- import { UnifiedApiExtension } from "storefront-middleware/types"
+ import { UnifiedEndpoints } from "storefront-middleware/types"

export const { getSdk } = createSdk(
  options,
-  ({ buildModule, middlewareUrl, getRequestHeaders }) => ({
-    commerce: buildModule(unifiedModule<UnifiedApiExtension>, {
-      apiUrl: `${middlewareUrl}/commerce`,
-      requestOptions: {
-        headers: getRequestHeaders,
+  ({ buildModule, middlewareModule, middlewareUrl, getRequestHeaders }) => ({
+    commerce: buildModule(middlewareModule<UnifiedEndpoints>, {
+      apiUrl: `${middlewareUrl}/commerce`,
+      defaultRequestConfig: {
+        headers: getRequestHeaders(),
      },
    }),
  })
);

@vue-storefront/[email protected]

Minor changes

  • [ADDED] middlewareModule to defineSdkConfig params.
- import { UnifiedApiExtension } from "storefront-middleware/types"
+ import { UnifiedEndpoints } from "storefront-middleware/types"

export default defineSdkConfig(
-  ({ buildModule, middlewareUrl, getRequestHeaders }) => ({
-    commerce: buildModule(unifiedModule<UnifiedApiExtension>, {
-      apiUrl: `${middlewareUrl}/commerce`,
-      requestOptions: { headers: getRequestHeaders },
+  ({ buildModule, middlewareModule, middlewareUrl, getRequestHeaders }) => ({
+      commerce: buildModule(middlewareModule<UnifiedEndpoints>, {
+        apiUrl: `${middlewareUrl}/commerce`,
+        defaultRequestConfig: { headers: getRequestHeaders() },
      }),
  })
);
  • [CHANGED] deprecate getCookieHeader, use getRequestHeaders instead
export default defineSdkConfig(
-  ({ buildModule, middlewareModule, middlewareUrl, getCookieHeader }) => ({
+  ({ buildModule, middlewareModule, middlewareUrl, getRequestHeaders }) => ({
      commerce: buildModule(middlewareModule<UnifiedEndpoints>, {
        apiUrl: `${middlewareUrl}/commerce`,
-        defaultRequestConfig: { headers: getCookieHeader() }, // Only cookie header is included.
+        defaultRequestConfig: { headers: getRequestHeaders() }, // All headers are included.
      }),
  })
);

@vue-storefront/[email protected]

2 months ago

Releases

@vue-storefront/[email protected]

Patch Changes

  • [CHANGED] Updated buildModule function to work well with modules, whether they have optional or mandatory options.

  • Simplified how buildModule is set up,

  • Added a new type, ModuleInitializerWithMandatoryOptions.

@vue-storefront/[email protected]

2 months ago

Releases

@vue-storefront/[email protected]

Minor Changes

  • 712ba85a6: [ADDED] Adds WithoutContext type helper.

    type ApiClientMethods = {
      getProduct: (context: any, id: string) => Promise<Product>;
    };
    
    type Endpoints = WithoutContext<ApiClientMethods>;
    

@vue-storefront/[email protected]

Patch Changes

@vue-storefront/[email protected]

2 months ago

Releases

@vue-storefront/[email protected]

Patch Changes

  • d95379e91: [FIXED] Type issue in multistore package. Cache control set method returns any type and get returns StoreConfig | undefined. Also, MiddlewareConfiguration type has been removed as it is no longer necessary.

@vue-storefront/[email protected]

3 months ago

Releases

@vue-storefront/[email protected]

Major Changes

  • 8ea533e05: [CHANGED] We standardized the way of creating and configuring multistore extension. Previously, the extension was created by importing multistoreExtension from @vue-storefront/multistore and passing it to the extensions function. Configuration was passed to the extension by adding multistore property to the configuration object. Now, the extension is created by calling createMultistoreExtension from @vue-storefront/multistore and passing the multistore configuration to it.

    - import { multistoreExtension } from "@vue-storefront/multistore";
    + import { createMultistoreExtension } from "@vue-storefront/multistore";
    import { multistoreConfig } from "./multistore.config";
    
    export default {
      integrations: {
        sapcc: {
          location: "@vue-storefront/sapcc-api/server",
          configuration: {
            // ...
    -        multistore: multistoreConfig,
          },
          extensions: (predefinedExtensions) => [
            ...predefinedExtensions,
    -        multistoreExtension,
    +        createMultistoreExtension(multistoreConfig),
          ],
        },
      },
    };
    
  • 8ea533e05: [FIXED] singleton cache issue, previously the cache was a singleton which could lead to unexpected behaviour when extension was used in different integrations in parallel. Now, the cache is being created during extension creation, what ensures proper cache behaviour.

@vue-storefront/[email protected]

3 months ago

Releases

@vue-storefront/[email protected]

Patch Changes

  • 44c067dff: [FIXED] Make the second generic argument in the buildModule function optional. It's not required for the buildModule function to have the second argument. In some cases, when the first generic argument was provided, the second one was required.

@vue-storefront/[email protected]

3 months ago

Releases

@vue-storefront/[email protected]

Patch Changes

  • 72826cd11: [FIXED] Resolved an issue where the option parameter type resolution in the buildModule function was not working correctly. The options parameter is now required or optional, depending on the module implementation.

@vue-storefront/[email protected]

3 months ago

Releases

@vue-storefront/[email protected]

Minor Changes

  • feec8789d: [ADDED] in this release we allowed extension to use module methods, access module configuration and optional context object. For more information please visit documentation about extending modules.

@vue-storefront/[email protected]

3 months ago

Releases

@vue-storefront/[email protected]

Patch Changes

  • c4534b523: Adjusted handling timeouts and aborting TCP connection