Replies: 1 comment 1 reply
-
|
I had a closer look at this against the current implementation and Google docs. Nuxt Scripts is doing the expected Consent Mode queueing here: The likely mismatch is Consent Mode semantics rather than the Nuxt Scripts API. With One other thing to check: your config has: $development: {
scripts: {
registry: {
googleTagManager: "mock",
},
},
}If Tag Assistant is pointed at a dev build, that mock config means the real GTM container/default consent setup is not what you are testing. I would test against a production/preview build without the mock, then inspect ["consent", "default", { ...denied state... }]
{ event: "gtm.js", "gtm.start": ... }
["consent", "update", { ...granted state... }]So my recommendation is:
References I checked:
|
Beta Was this translation helpful? Give feedback.



Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I built a custom cookie banner and am trying to make it work with GTM Consent Mode.
In
nuxt.config.ts, I've got the following config:In my
app.vue, I've got something along the lines of:I've done this in an attempt to debug the consent mode. In reality, I have a composable (
useCookieConsent()) that would track cookie banner consent in a reactive which I watch on for changes, which in turn will to the consent update.For some reason my tags are always loaded even initially, when cookies should be rejected. This is why I am trying to debug it using the Tag Assistant. However, the Tag Assistant never shows anything related to consent as seen in the following screenshot. Neither the default consent nor the consent update appear. As I understand it, it should display the configured consent in the consent (Einwilligung) tab, as well as show a consent event on the left.
Any ideas what I might be doing wrong?
Beta Was this translation helpful? Give feedback.
All reactions