Timer not pausing as expected #155
-
Hi, I am trying to make my timer pause but instead of pausing, the timer gets reset. Attached is the relevant code snippet: https://codesandbox.io/s/async-feather-9xby0?file=/src/App.js I am not sure why this is the case as I tinkered with the example code, using a similar approach and it seems to work: https://codesandbox.io/s/nameless-dawn-kcxoq?file=/src/index.js Help is appreciated, thank you! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
Hey, is it possible that you also press the reset button? Can you try to remove it and see what would ne result? |
Beta Was this translation helpful? Give feedback.
-
Hi. I had the same problem. To future readers: I moved the 'countdown-circle-timer' component from its own component into the parent render method. Must have been a problem with scope. |
Beta Was this translation helpful? Give feedback.
Hey, is it possible that you also press the reset button? Can you try to remove it and see what would ne result?