Closed tamirble closed 1 year ago
I have added getIdleTime
and getActiveTime
that will be reset when reset
is called. The getTotal*
methods will keep track for the entire life of the component. This will be in the next release. If you want to test it out, you can install the latest release candidate with npm i react-idle-timer@next
.
Bug information
Affected Module
Version
: 5.4.2Describe the bug
Calling the reset function sometimes leave the getTotalActiveTime value on 0 without any movement
To Reproduce
Steps to reproduce the behavior: I've prepared the following sandbox for it: https://codesandbox.io/s/idle-timer-forked-3rggu9
Expected behavior
I would expect the getTotalActiveTime function to start counting according to its name
Screenshots
If applicable, add screenshots to help explain your problem.
System Information (please complete the following information)
OS
: MacOsDevice
: MacbookBrowser Vendor
: chromeBrowser Version
: 107.0.5304.110Additional context
You can also see a video of the problem here: https://streamable.com/a2xw4i