Skip to content

Commit 8889df3

Browse files
committed
fix: pass masterConsentsOrigin as URL param and merge duplicate integrations key
The masterConsentsOrigin was set as a data attribute instead of a URL query parameter, so Termly never read it and consent sync between www.kosli.com and docs.kosli.com did not work. Also merges the two duplicate `integrations` keys in docs.json — the second silently overwrote the first, dropping the cookies config.
1 parent 85e8b99 commit 8889df3

2 files changed

Lines changed: 5 additions & 8 deletions

File tree

docs.json

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -36,12 +36,6 @@
3636
"metadata": {
3737
"timestamp": true
3838
},
39-
"integrations": {
40-
"cookies": {
41-
"key": "kosli_consent",
42-
"value": "accepted"
43-
}
44-
},
4539
"favicon": "/favicon-32x32.png",
4640
"redirects": {
4741
"$ref": "./config/redirects.json"
@@ -79,6 +73,10 @@
7973
]
8074
},
8175
"integrations": {
76+
"cookies": {
77+
"key": "kosli_consent",
78+
"value": "accepted"
79+
},
8280
"mixpanel": {
8381
"projectToken": "bf8ac483215f65141ab7ad825b079662"
8482
}

termly.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,7 @@
3232
if (!document.getElementById("kosli-termly-embed")) {
3333
const s = document.createElement("script");
3434
s.id = "kosli-termly-embed";
35-
s.src = "https://app.termly.io/resource-blocker/c98bfcd6-2f30-4f3c-b53c-d6dbd9b8c40c?autoBlock=on";
36-
s.setAttribute("data-master-consents-origin", "https://www.kosli.com");
35+
s.src = "https://app.termly.io/resource-blocker/c98bfcd6-2f30-4f3c-b53c-d6dbd9b8c40c?autoBlock=on&masterConsentsOrigin=https://www.kosli.com";
3736
s.setAttribute("onload", "onTermlyLoaded()");
3837
document.head.appendChild(s);
3938
}

0 commit comments

Comments
 (0)