Hi, I'm having the issue that once a user changes the consent from accept to deny to connection to GTM still persists. I have tried overwriting the gtmParms on consent change without success (arbitrary strings or undefined). Collect still pops up in the network tab.
Also I tried to tie useGTMDispatch to the condition of consent being true. Which works but once a consent change happens such as false, true, false, I still get data getting sent to GTM.
It seems no matter what what I do, once the react gtm hook connects to GTM ,its connection can not be disabled again.
Has anyone ever run into this problem or knows a way out?
Hi, I'm having the issue that once a user changes the consent from accept to deny to connection to GTM still persists. I have tried overwriting the gtmParms on consent change without success (arbitrary strings or undefined). Collect still pops up in the network tab.
Also I tried to tie
useGTMDispatch
to the condition of consent being true. Which works but once a consent change happens such asfalse
,true
,false
, I still get data getting sent to GTM.It seems no matter what what I do, once the react gtm hook connects to GTM ,its connection can not be disabled again. Has anyone ever run into this problem or knows a way out?