arky-sdk 0.9.6 → 0.9.12
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/README.md +113 -194
- package/dist/admin-D8HiRDCl.d.cts +1536 -0
- package/dist/admin-Dnnv18wN.d.ts +1536 -0
- package/dist/admin.cjs +832 -375
- package/dist/admin.cjs.map +1 -1
- package/dist/admin.d.cts +3 -3
- package/dist/admin.d.ts +3 -3
- package/dist/admin.js +832 -375
- package/dist/admin.js.map +1 -1
- package/dist/api-D4lMmvF0.d.cts +4337 -0
- package/dist/api-D4lMmvF0.d.ts +4337 -0
- package/dist/{index-nCF3Z6Af.d.cts → index-BS2x278C.d.cts} +1 -1
- package/dist/{index-CZxubTDA.d.ts → index-Be8suRwP.d.ts} +1 -1
- package/dist/index.cjs +934 -460
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +3 -3
- package/dist/index.d.ts +3 -3
- package/dist/index.js +934 -460
- package/dist/index.js.map +1 -1
- package/dist/storefront.cjs +501 -300
- package/dist/storefront.cjs.map +1 -1
- package/dist/storefront.d.cts +174 -89
- package/dist/storefront.d.ts +174 -89
- package/dist/storefront.js +499 -299
- package/dist/storefront.js.map +1 -1
- package/dist/types.cjs.map +1 -1
- package/dist/types.d.cts +1 -1
- package/dist/types.d.ts +1 -1
- package/dist/types.js.map +1 -1
- package/dist/utils.d.cts +2 -2
- package/dist/utils.d.ts +2 -2
- package/package.json +7 -10
- package/scripts/contract-admin.mjs +137 -0
- package/scripts/contract-storefront.mjs +296 -0
- package/dist/admin-DjYydKeB.d.ts +0 -1389
- package/dist/admin-DlL8mCxL.d.cts +0 -1389
- package/dist/api-BbBHcd4p.d.cts +0 -3289
- package/dist/api-BbBHcd4p.d.ts +0 -3289
- package/dist/storefront-store.cjs +0 -2809
- package/dist/storefront-store.cjs.map +0 -1
- package/dist/storefront-store.d.cts +0 -5
- package/dist/storefront-store.d.ts +0 -5
- package/dist/storefront-store.js +0 -2807
- package/dist/storefront-store.js.map +0 -1
- package/scripts/smoke-store.mjs +0 -41
package/scripts/smoke-store.mjs
DELETED
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
import assert from "node:assert/strict";
|
|
3
|
-
import { createArkyStore } from "../dist/storefront-store.js";
|
|
4
|
-
|
|
5
|
-
const store = createArkyStore({
|
|
6
|
-
baseUrl: "http://127.0.0.1:1",
|
|
7
|
-
storeId: "smoke-store",
|
|
8
|
-
market: "us",
|
|
9
|
-
locale: "en",
|
|
10
|
-
});
|
|
11
|
-
|
|
12
|
-
assert.equal("cart" in store, false, "cart must live under eshop.cart");
|
|
13
|
-
assert.equal("booking" in store, false, "service scheduling must live under eshop.service");
|
|
14
|
-
assert.equal(typeof store.initialize, "function");
|
|
15
|
-
assert.equal(typeof store.setup, "function");
|
|
16
|
-
assert.equal(typeof store.setContext, "function");
|
|
17
|
-
assert.equal(typeof store.me, "function");
|
|
18
|
-
assert.equal(typeof store.onAuthStateChanged, "function");
|
|
19
|
-
assert.equal(store.currentSession, null);
|
|
20
|
-
assert.equal(store.isAuthenticated, false);
|
|
21
|
-
store.setContext({ locale: "en", market: "us" });
|
|
22
|
-
assert.equal(store.getLocale(), "en");
|
|
23
|
-
assert.equal(store.getMarket(), "us");
|
|
24
|
-
assert.equal(typeof store.cms.node.get, "function");
|
|
25
|
-
assert.equal("website" in store.cms, false, "CMS node keys must not be public SDK methods");
|
|
26
|
-
assert.equal(typeof store.activity.pageView, "function");
|
|
27
|
-
assert.equal("actions" in store.eshop.cart, false, "cart commands should be direct methods");
|
|
28
|
-
assert.equal("actions" in store.eshop.service, false, "service commands should be direct methods");
|
|
29
|
-
assert.equal(typeof store.eshop.cart.ensure, "function");
|
|
30
|
-
assert.equal(typeof store.eshop.cart.checkout, "function");
|
|
31
|
-
assert.equal(typeof store.eshop.product.list, "function");
|
|
32
|
-
assert.equal(typeof store.eshop.product.loadDetail, "function");
|
|
33
|
-
assert.equal(typeof store.eshop.service.listProviders, "function");
|
|
34
|
-
assert.equal(typeof store.eshop.service.initialize, "function");
|
|
35
|
-
assert.equal(typeof store.eshop.service.select, "function");
|
|
36
|
-
const legacyServiceModuleName = "service" + "Order";
|
|
37
|
-
assert.equal(legacyServiceModuleName in store.eshop, false, "scheduled service controls belong under eshop.service");
|
|
38
|
-
assert.equal(store.eshop.cart.product_items.get().length, 0);
|
|
39
|
-
assert.equal(store.eshop.service.state.get().cart.length, 0);
|
|
40
|
-
|
|
41
|
-
console.log("Storefront store smoke test passed.");
|