segmentio / consent-manager

Drop-in consent management plugin for analytics.js
https://segmentio.github.io/consent-manager/
MIT License
341 stars 142 forks source link

Gatsby not show banner #218

Closed ferrero1987 closed 2 years ago

ferrero1987 commented 2 years ago

Hi, When using gatsby, the blue banner doesn’t show up Schermata 2022-04-08 alle 15 17 27

The code is here: https://codesandbox.io/s/kmvzm?file=/src/components/layout.js:2212-2613

maurocanuto commented 2 years ago

+1

edsonjab commented 2 years ago

Hi @ferrero1987 @maurocanuto, We still work on that issue but for the moment you can add the attribute "otherWriteKeys" that would help to show the banner

gatsbyError

maurocanuto commented 2 years ago

@edsonjab thanks for the help. What is the value to use for the otherWriteKeys? Is that another Write Key that we need to generate or the Source ID?

nd4p90x commented 2 years ago

@maurocanuto This is a secondary write key for another segment instance. We found an issue where if this field is missing, the banner doesn't display properly with Gatsby. We are currently working on a solution and will update the issue soon.

edsonjab commented 2 years ago

Hi @maurocanuto to show the banner, you need has configure at least one destination on your segment added to your source, that will be take more less 24 hrs to be reflected and after that you will see the Banner on your app. You can use this URL to check if your key has destinations configured https://cdn.segment.com/v1/projects/YOUR_WRITE_KEY/integrations

maurocanuto commented 2 years ago

@edsonjab Thanks! By adding a destination seems to be working now!