commerce-sdk-isomorphic 4.0.1-preview-shopper-test.0 → 4.1.0

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.
Files changed (74) hide show
  1. package/README.md +57 -0
  2. package/lib/clientConfig.cjs.d.ts +4 -2
  3. package/lib/clientConfig.cjs.js +1 -1
  4. package/lib/clientConfig.d.ts +4 -2
  5. package/lib/clientConfig.js +1 -1
  6. package/lib/helpers.cjs.d.ts +9 -9
  7. package/lib/helpers.cjs.js +1 -1
  8. package/lib/helpers.d.ts +9 -9
  9. package/lib/helpers.js +1 -1
  10. package/lib/index.cjs.d.ts +57 -24
  11. package/lib/index.cjs.js +1 -1
  12. package/lib/index.esm.d.ts +57 -24
  13. package/lib/index.esm.js +1 -1
  14. package/lib/shopperBaskets.cjs.d.ts +6 -1
  15. package/lib/shopperBaskets.cjs.js +1 -1
  16. package/lib/shopperBaskets.d.ts +6 -1
  17. package/lib/shopperBaskets.js +1 -1
  18. package/lib/shopperBasketsv2.cjs.d.ts +6 -1
  19. package/lib/shopperBasketsv2.cjs.js +1 -1
  20. package/lib/shopperBasketsv2.d.ts +6 -1
  21. package/lib/shopperBasketsv2.js +1 -1
  22. package/lib/shopperConsents.cjs.d.ts +6 -1
  23. package/lib/shopperConsents.cjs.js +1 -1
  24. package/lib/shopperConsents.d.ts +6 -1
  25. package/lib/shopperConsents.js +1 -1
  26. package/lib/shopperContext.cjs.d.ts +6 -1
  27. package/lib/shopperContext.cjs.js +1 -1
  28. package/lib/shopperContext.d.ts +6 -1
  29. package/lib/shopperContext.js +1 -1
  30. package/lib/shopperCustomers.cjs.d.ts +6 -1
  31. package/lib/shopperCustomers.cjs.js +1 -1
  32. package/lib/shopperCustomers.d.ts +6 -1
  33. package/lib/shopperCustomers.js +1 -1
  34. package/lib/shopperExperience.cjs.d.ts +6 -1
  35. package/lib/shopperExperience.cjs.js +1 -1
  36. package/lib/shopperExperience.d.ts +6 -1
  37. package/lib/shopperExperience.js +1 -1
  38. package/lib/shopperGiftCertificates.cjs.d.ts +6 -1
  39. package/lib/shopperGiftCertificates.cjs.js +1 -1
  40. package/lib/shopperGiftCertificates.d.ts +6 -1
  41. package/lib/shopperGiftCertificates.js +1 -1
  42. package/lib/shopperLogin.cjs.d.ts +6 -1
  43. package/lib/shopperLogin.cjs.js +1 -1
  44. package/lib/shopperLogin.d.ts +6 -1
  45. package/lib/shopperLogin.js +1 -1
  46. package/lib/shopperOrders.cjs.d.ts +6 -1
  47. package/lib/shopperOrders.cjs.js +1 -1
  48. package/lib/shopperOrders.d.ts +6 -1
  49. package/lib/shopperOrders.js +1 -1
  50. package/lib/shopperProducts.cjs.d.ts +6 -1
  51. package/lib/shopperProducts.cjs.js +1 -1
  52. package/lib/shopperProducts.d.ts +6 -1
  53. package/lib/shopperProducts.js +1 -1
  54. package/lib/shopperPromotions.cjs.d.ts +6 -1
  55. package/lib/shopperPromotions.cjs.js +1 -1
  56. package/lib/shopperPromotions.d.ts +6 -1
  57. package/lib/shopperPromotions.js +1 -1
  58. package/lib/shopperSearch.cjs.d.ts +6 -1
  59. package/lib/shopperSearch.cjs.js +1 -1
  60. package/lib/shopperSearch.d.ts +6 -1
  61. package/lib/shopperSearch.js +1 -1
  62. package/lib/shopperSeo.cjs.d.ts +6 -1
  63. package/lib/shopperSeo.cjs.js +1 -1
  64. package/lib/shopperSeo.d.ts +6 -1
  65. package/lib/shopperSeo.js +1 -1
  66. package/lib/shopperStores.cjs.d.ts +6 -1
  67. package/lib/shopperStores.cjs.js +1 -1
  68. package/lib/shopperStores.d.ts +6 -1
  69. package/lib/shopperStores.js +1 -1
  70. package/lib/version.cjs.d.ts +1 -1
  71. package/lib/version.cjs.js +1 -1
  72. package/lib/version.d.ts +1 -1
  73. package/lib/version.js +1 -1
  74. package/package.json +4 -4
@@ -70,6 +70,7 @@ type BrowserRequestInit = RequestInit;
70
70
  * Using the right properties in the right context is left to the user.
71
71
  */
72
72
  type FetchOptions = NodeRequestInit & BrowserRequestInit;
73
+ type FetchFunction = (input: RequestInfo, init?: FetchOptions | undefined) => Promise<Response>;
73
74
  /**
74
75
  * Base options that can be passed to the `ClientConfig` class.
75
76
  */
@@ -81,6 +82,7 @@ interface ClientConfigInit<Params extends BaseUriParameters> {
81
82
  };
82
83
  parameters: Params;
83
84
  fetchOptions?: FetchOptions;
85
+ fetch?: FetchFunction;
84
86
  transformRequest?: (data: unknown, headers: {
85
87
  [key: string]: string;
86
88
  }) => Required<FetchOptions>["body"];
@@ -97,6 +99,7 @@ declare class ClientConfig<Params extends BaseUriParameters> implements ClientCo
97
99
  };
98
100
  parameters: Params;
99
101
  fetchOptions: FetchOptions;
102
+ fetch?: FetchFunction;
100
103
  transformRequest: NonNullable<ClientConfigInit<Params>["transformRequest"]>;
101
104
  throwOnBadResponse: boolean;
102
105
  constructor(config: ClientConfigInit<Params>);
@@ -4855,6 +4858,7 @@ declare namespace ShopperCustomersApiTypes {
4855
4858
  * Using the right properties in the right context is left to the user.
4856
4859
  */
4857
4860
  type FetchOptions = NodeRequestInit & BrowserRequestInit;
4861
+ type FetchFunction = (input: RequestInfo, init?: FetchOptions | undefined) => Promise<Response>;
4858
4862
  /**
4859
4863
  * Base options that can be passed to the `ClientConfig` class.
4860
4864
  */
@@ -4866,12 +4870,12 @@ declare namespace ShopperCustomersApiTypes {
4866
4870
  };
4867
4871
  parameters: Params;
4868
4872
  fetchOptions?: FetchOptions;
4873
+ fetch?: FetchFunction;
4869
4874
  transformRequest?: (data: unknown, headers: {
4870
4875
  [key: string]: string;
4871
4876
  }) => Required<FetchOptions>["body"];
4872
4877
  throwOnBadResponse?: boolean;
4873
4878
  }
4874
- type FetchFunction = (input: RequestInfo, init?: FetchOptions | undefined) => Promise<Response>;
4875
4879
  /**
4876
4880
  * Configuration parameters common to Commerce SDK clients
4877
4881
  */
@@ -4883,6 +4887,7 @@ declare namespace ShopperCustomersApiTypes {
4883
4887
  };
4884
4888
  parameters: Params;
4885
4889
  fetchOptions: FetchOptions;
4890
+ fetch?: FetchFunction;
4886
4891
  transformRequest: NonNullable<ClientConfigInit<Params>["transformRequest"]>;
4887
4892
  throwOnBadResponse: boolean;
4888
4893
  constructor(config: ClientConfigInit<Params>);