Skip to main content
Answered

Is it possible to conditionally show a product tour based on a presence of an element?

  • July 29, 2021
  • 1 reply
  • 485 views

I would like to have the Product Tour show up only if we have a particular element on the screen (e.g. start it only if we have a particular box on the screen).

 

The solutions that I can think of are:

  1. Trigger a JS event once the box has shown up and then filter if the event has a count of greater than 0. However, that doesn't seem to always work for us. Once the event gets trigger, the product tour doesn't show up. We seem to have to always refresh the page in order for the tour to show up.
  2. Do something like this - Intercom('startTour', tourId) - aka trigger this event once the element shows up. However, this requires us to create the product tour first and find the tour id.

 

Are there better ways of doing this? Ideally, I would like to just have something in the product tour setup to specifically say "if this named element is present, start this tour".

 

For context, we have a React based application that has a lot of interactivity.

Best answer by Roy

Hello @michelle c11​ ,

 

You can also add some people's attributes, call them "elements" and send all the elements in text format separated by a comma.

Example:

"Elements = Name1, Name2, Name3"

 

Then during product tour configuration, select the following element in rules and contains = Name1.

 

In this way will be much easier to develop and launch this ASAP.

View original
Did this topic help you find an answer to your question?

1 reply

Forum|alt.badge.img+5
  • Expert User
  • 1152 replies
  • Answer
  • July 29, 2021

Hello @michelle c11​ ,

 

You can also add some people's attributes, call them "elements" and send all the elements in text format separated by a comma.

Example:

"Elements = Name1, Name2, Name3"

 

Then during product tour configuration, select the following element in rules and contains = Name1.

 

In this way will be much easier to develop and launch this ASAP.


Reply


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