@sitecore-jss/sitecore-jss-nextjs 21.1.0-canary.8 → 21.1.0-canary.9
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.
|
@@ -96,10 +96,11 @@ class PersonalizeMiddleware {
|
|
|
96
96
|
// (underlying default 'cross-fetch' is not currently compatible: https://github.com/lquixada/cross-fetch/issues/78)
|
|
97
97
|
this.personalizeService = new personalize_1.GraphQLPersonalizeService(Object.assign(Object.assign({}, config.edgeConfig), { fetch: fetch }));
|
|
98
98
|
// NOTE: same here, we provide NativeDataFetcher for compatibility on Next.js Edge Runtime
|
|
99
|
-
this.cdpService = new personalize_1.CdpService(Object.assign(Object.assign({}, config.cdpConfig), { dataFetcherResolver: ({ timeout }) => {
|
|
99
|
+
this.cdpService = new personalize_1.CdpService(Object.assign(Object.assign({}, config.cdpConfig), { dataFetcherResolver: ({ timeout, headers, }) => {
|
|
100
100
|
const fetcher = new sitecore_jss_1.NativeDataFetcher({
|
|
101
101
|
debugger: sitecore_jss_1.debug.personalize,
|
|
102
102
|
timeout,
|
|
103
|
+
headers,
|
|
103
104
|
});
|
|
104
105
|
return (url, data) => fetcher.fetch(url, data);
|
|
105
106
|
} }));
|
|
@@ -93,10 +93,11 @@ export class PersonalizeMiddleware {
|
|
|
93
93
|
// (underlying default 'cross-fetch' is not currently compatible: https://github.com/lquixada/cross-fetch/issues/78)
|
|
94
94
|
this.personalizeService = new GraphQLPersonalizeService(Object.assign(Object.assign({}, config.edgeConfig), { fetch: fetch }));
|
|
95
95
|
// NOTE: same here, we provide NativeDataFetcher for compatibility on Next.js Edge Runtime
|
|
96
|
-
this.cdpService = new CdpService(Object.assign(Object.assign({}, config.cdpConfig), { dataFetcherResolver: ({ timeout }) => {
|
|
96
|
+
this.cdpService = new CdpService(Object.assign(Object.assign({}, config.cdpConfig), { dataFetcherResolver: ({ timeout, headers, }) => {
|
|
97
97
|
const fetcher = new NativeDataFetcher({
|
|
98
98
|
debugger: debug.personalize,
|
|
99
99
|
timeout,
|
|
100
|
+
headers,
|
|
100
101
|
});
|
|
101
102
|
return (url, data) => fetcher.fetch(url, data);
|
|
102
103
|
} }));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sitecore-jss/sitecore-jss-nextjs",
|
|
3
|
-
"version": "21.1.0-canary.
|
|
3
|
+
"version": "21.1.0-canary.9",
|
|
4
4
|
"main": "dist/cjs/index.js",
|
|
5
5
|
"module": "dist/esm/index.js",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -70,16 +70,16 @@
|
|
|
70
70
|
"react-dom": "^18.1.0"
|
|
71
71
|
},
|
|
72
72
|
"dependencies": {
|
|
73
|
-
"@sitecore-jss/sitecore-jss": "^21.1.0-canary.
|
|
74
|
-
"@sitecore-jss/sitecore-jss-dev-tools": "^21.1.0-canary.
|
|
75
|
-
"@sitecore-jss/sitecore-jss-react": "^21.1.0-canary.
|
|
73
|
+
"@sitecore-jss/sitecore-jss": "^21.1.0-canary.9",
|
|
74
|
+
"@sitecore-jss/sitecore-jss-dev-tools": "^21.1.0-canary.9",
|
|
75
|
+
"@sitecore-jss/sitecore-jss-react": "^21.1.0-canary.9",
|
|
76
76
|
"prop-types": "^15.7.2",
|
|
77
77
|
"regex-parser": "^2.2.11",
|
|
78
78
|
"sync-disk-cache": "^2.1.0"
|
|
79
79
|
},
|
|
80
80
|
"description": "",
|
|
81
81
|
"types": "types/index.d.ts",
|
|
82
|
-
"gitHead": "
|
|
82
|
+
"gitHead": "4a2c3e38ee8e96be5a36efe093462de7037f1c33",
|
|
83
83
|
"files": [
|
|
84
84
|
"dist",
|
|
85
85
|
"types",
|