@okendo/shopify-hydrogen 2.5.1 → 2.5.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.
Files changed (2) hide show
  1. package/README.md +6 -9
  2. package/package.json +1 -1
package/README.md CHANGED
@@ -74,26 +74,23 @@ Locate the `Layout` component, add the `meta` tag `oke:subscriber_id` to `head`,
74
74
  </head>
75
75
  ```
76
76
 
77
- Append `OkendoProvider` to `body`, and pass it the promise returned by `getOkendoProviderData`. If Content Security Policy is active in your project, you also need to provide the `nonce` (available with `const nonce = useNonce()` in Shopify's Hydrogen demo store):
77
+ Locate the `App` function, append `OkendoProvider`, and pass it the promise returned by `getOkendoProviderData`. If Content Security Policy is active in your project, you also need to provide the `nonce` (available with `const nonce = useNonce()` in Shopify's Hydrogen demo store):
78
78
 
79
79
  ```tsx
80
80
  <body>
81
- {data ? (
81
+ return (
82
82
  <OkendoProvider nonce={nonce} okendoProviderData={data.okendoProviderData}>
83
83
  <Analytics.Provider
84
84
  cart={data.cart}
85
85
  shop={data.shop}
86
86
  consent={data.consent}
87
87
  >
88
- <PageLayout {...data}>{children}</PageLayout>
88
+ <PageLayout {...data}>
89
+ <Outlet />
90
+ </PageLayout>
89
91
  </Analytics.Provider>
90
92
  </OkendoProvider>
91
- ) : (
92
- children
93
- )}
94
- <ScrollRestoration nonce={nonce} />
95
- <Scripts nonce={nonce} />
96
- </body>
93
+ );
97
94
  ```
98
95
 
99
96
  ### `app/entry.server.tsx`
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@okendo/shopify-hydrogen",
3
- "version": "2.5.1",
3
+ "version": "2.5.2",
4
4
  "description": "Okendo React components for Shopify Hydrogen",
5
5
  "author": "Okendo",
6
6
  "license": "SEE LICENSE IN LICENSE.txt",