Is it possible to call useIdleTimer with same name multiple times?
#270
-
|
I have two components: |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
|
Hey @tuhin-tsm!
https://idletimer.dev/docs/getting-started/new#cross-tab-messaging Maybe you can take advantage of the Here are the docs for the Provider: |
Beta Was this translation helpful? Give feedback.
Hey @tuhin-tsm!
IdleTimerexposes the underlying messaging channel for you to use how ever you like. You can find the relevant docs here:https://idletimer.dev/docs/getting-started/new#cross-tab-messaging
Maybe you can take advantage of the
IdleTimerProviderto avoid the need for drilling props, but it sounds like you might have an inversion of control issue. Could you share a little code to help me understand your set up?Here are the docs for the Provider:
https://idletimer.dev/docs/api/idle-timer-provider