@ecomiq/core 0.1.1 → 0.1.2

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/dist/client.cjs CHANGED
@@ -819,6 +819,11 @@ async function getCollections(api) {
819
819
  async function getCollectionBySlug(api, collectionSlug) {
820
820
  return api.get(`collections/${encodeURIComponent(collectionSlug)}`, CollectionSchema);
821
821
  }
822
+
823
+ // src/services/page.service.ts
824
+ async function getPageBySlug(api, pageSlug) {
825
+ return api.get(`pages/${encodeURIComponent(pageSlug)}`, CmsPageDetailsDtoSchema);
826
+ }
822
827
  var CartBuyerParamsSchema = zod.z.object({
823
828
  cartId: zod.z.string().uuid(),
824
829
  email: zod.z.string().email(),
@@ -1211,6 +1216,10 @@ function createClient(options) {
1211
1216
  const client = await apiClient();
1212
1217
  return getCollectionBySlug(client, collectionSlug);
1213
1218
  }
1219
+ async function getPageBySlug2(pageSlug) {
1220
+ const client = await apiClient();
1221
+ return getPageBySlug(client, pageSlug);
1222
+ }
1214
1223
  async function getProducts2(params = {}) {
1215
1224
  const client = await apiClient();
1216
1225
  return getProducts(client, params);
@@ -1309,6 +1318,7 @@ function createClient(options) {
1309
1318
  getStoreId,
1310
1319
  getCollections: getCollections2,
1311
1320
  getCollectionBySlug: getCollectionBySlug2,
1321
+ getPageBySlug: getPageBySlug2,
1312
1322
  clearCache,
1313
1323
  getProducts: getProducts2,
1314
1324
  getProductBySlug: getProductBySlug2,