25 + 5 Clock Test Failed

Here is my current code for the challenge: https://codepen.io/Vincent97/pen/MWqXQMX?editors=0011

My code has passed 28 out of 29 tests so far, except for the test #14 in the Timer section. When my code runs for this test, the value of ‘Session Length’ is -36 after the session timer reaches ‘00:00’. I have spent a whole day trying to figure out which part of my code triggers this bug; however, I can’t detect any.

Please run the test for my code first to see the situation that I described above.

Therefore, I hope that anyone here can help me point out what is wrong with my code.

Thank you so much in advance.

See this issue. Your details match what I was seeing in testing for that issue.

You can try downgrading to react 16 or 17, which batches updates differently and therefore works.

Also, you can load react and friends with the JS configuration in codepen so you don’t have to pull them in via script tags.

Thank you so much for taking the time to help me figure out how to fix the problem. I really appreciate you.

I did as you recommended by using React v17.0.0, and my code passed all of the tests :+1:

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.