Skip to content

Troubleshooting

Start by running LightningCMP.debug() — most issues show up in its hints.

Section titled ““A tag read consent state before a default was set” (GTM Preview)”

A Google tag initialised before the Consent Mode default landed. Almost always a deferred-JS optimiser reordering your scripts. Add data-cfasync="false" to every Lightning <script> (Cloudflare Rocket Loader), or exclude them from WP Rocket / LiteSpeed / NitroPack. If a site-hosted GTM/gtag tag is the culprit, either move the inline gtag('consent','default',{…denied…}) block above it or let the CMP load the tag via bridges.google.tagId.

  • The visitor’s region may resolve to no banner (outside GDPR/US law), or a stored decision already exists — run LightningCMP.reset() to clear it.
  • The page host may not be an authorised domain — the SDK no-ops off-domain. Check the dashboard; localhost is allowed for testing.

Either it’s not gated (add the script blocker markup or a bridge) or it’s injected by GTM — gate it inside GTM via Consent Settings, not by blocking the container.

You probably hard-blocked a Google tag. Bridge it instead so cookieless Consent Mode pings and modelling keep working.