Skip to content

Commit

Permalink
added code for clarity to track consent for the user and set cookies
Browse files Browse the repository at this point in the history
  • Loading branch information
sarahcrack committed Jan 22, 2025
1 parent d5d8368 commit 1701d65
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions app/webpacker/javascript/clarity.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ export default class Clarity {
document.addEventListener('cookies:accepted', () => {
if (this.consentValue('non-functional') === 'granted') {
this.initContainer();
window.clarity('consent');
}
});
}
Expand Down

0 comments on commit 1701d65

Please sign in to comment.