tier-tool for Cookie consent : how to categorize destinations
We are using a tier-tool that displays a cookie banner to the user. He then can check or uncheck the categories of cookies he wants to allow/disallow. Our categories are for example: "statistics" or "marketing".
In order to show these categories, we need to add data-attributes to each script used by the page.
Eg. Google Analytics script should have a data-attribute related to "statistics" -> shows a checkbox "statistics" to the end-user
But as we are using Segment, all the destinations are hidden in the pageload. How can we work with this?
I know there is a Segment consent solution implemented but as we started to use the other tool, I would like to dig in without changing it at this moment.
Thanks a lot!
Sorry for the late reply :)
The ready method allows you to pass in a callback that will be called as soon as all of your enabled integrations have loaded and analytics.js has completed initialization giving you access to end-tool library methods:
Check out our docs for a bit more info: https://segment.com/docs/sources/website/analytics.js/#ready
Was this helpful? Let me know if I can answer any additional questions, and cheers!Reply