Skip to main content
Question

close in-app messages by clicking outside of ui

  • October 30, 2024
  • 1 reply
  • 53 views

Hello

What we have:

We have a web app (build with next.js) and browser chrome extension (build with react.js).

We use @customerio/cdp-analytics-browser  in both apps.

What we want (1):

We want to close (dismiss) in-app messages, but we want to trigger closing in customer.io npm package (@customerio/cdp-analytics-browser). Is it possible? We don’t find a method for that.

What we find, that we can do the same but with react-native sdk, by running:

CustomerIO.inAppMessaging().dismissMessage();

but react-native it is not what we need. Now we just remove in-app messages iframe from DOM, which is not a great way how to handle this.
 

What we want (2):

We have a functionality to disable chrome browser extension for some domains (for example user don’t want to use our browser extension for google.com).

And we want to disable or stop notifications for that user. Is it possible? We know that we can use

_cio.reset();

but in that case when we have in-app messages in customer.io queue will we still get them?

Thanks a lot for the help!

 

1 reply

  • Author
  • Novice
  • 1 reply
  • October 31, 2024

i also can add, that there is no way how to do it via iframe, due to Same Origin Police


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings