Skip to content

Can we use spotlightClicks without a controlled/stepIndex mode? #665

Closed Answered by gilbarbara
jimmythecode asked this question in Q&A
Discussion options

You must be logged in to vote

hey @jimmythecode

The spotlightClicks works with both modes, uncontrolled or controlled.
However, this library only has control of the elements it creates, so clicking a button in your code won't have any direct effect on the tour...

If you need the tour to work in different contexts (routes in your case) then you'll need to use the controlled mode.

You'll need a handler in this button to stop the tour, increase the stepIndex, and after the route loads (and your next target is visible) start the tour again.

Replies: 1 comment 9 replies

Comment options

You must be logged in to vote
9 replies
@jimmythecode
Comment options

@gilbarbara
Comment options

@gilbarbara
Comment options

@jimmythecode
Comment options

@gilbarbara
Comment options

Answer selected by gilbarbara
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants