Skip to content

Commit

Permalink
Load GA4/Google Ads when Google Consent Mode is on
Browse files Browse the repository at this point in the history
  • Loading branch information
AmauriC committed Mar 5, 2024
1 parent 71eeae9 commit 05de442
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions tarteaucitron.js
Original file line number Diff line number Diff line change
Expand Up @@ -392,6 +392,10 @@ var tarteaucitron = {
// allow gtag/googleads by default if consent mode is on
window.addEventListener('tac.root_available', function() {
tarteaucitron_block.unblock(/www\.googletagmanager\.com\/gtag\/js/);

This comment has been minimized.

Copy link
@Olegcho

Olegcho Mar 6, 2024

tarteaucitron_block is not defined

This comment has been minimized.

Copy link
@AmauriC

AmauriC Mar 6, 2024

Author Owner

Merci 🙏
e8d655a

tarteaucitron_block.unblock(/www\.googleadservices\.com\/pagead\/conversion/);
tarteaucitron_block.unblock(/AW-/);
tarteaucitron_block.unblock(/google-analytics\.com\/analytics\.js/);
tarteaucitron_block.unblock(/google-analytics\.com\/ga\.js/);
});
}

Expand Down
2 changes: 1 addition & 1 deletion tarteaucitron.min.js

Large diffs are not rendered by default.

0 comments on commit 05de442

Please sign in to comment.