Merge pull request #939 from alexandrebrubeyonds/klaviyo

add Klaviyo service
This commit is contained in:
Amauri CHAMPEAUX 2022-05-10 18:44:23 +02:00 committed by GitHub
commit c98a0e9bd2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 17 additions and 0 deletions

View File

@ -5326,3 +5326,20 @@ tarteaucitron.services.tiktok = {
tarteaucitron.addScript('https://analytics.tiktok.com/i18n/pixel/sdk.js?sdkid=' + tarteaucitron.user.tiktokId);
}
};
// Klaviyo
tarteaucitron.services.klaviyo = {
"key": "klaviyo",
"type": "ads",
"name": "Klaviyo",
"uri": "https://help.klaviyo.com/hc/en-us/articles/360034666712-About-Cookies-in-Klaviyo",
"needConsent": true,
"cookies": ['__kla_id'],
"js": function () {
"use strict";
if (tarteaucitron.user.klaviyoCompanyId === undefined) {
return;
}
tarteaucitron.addScript('//static.klaviyo.com/onsite/js/klaviyo.js?company_id=' + tarteaucitron.user.klaviyoCompanyId);
}
};